If the franchise is run badly it will damage the franchiser’s name. This may harm the sales of other franchises and reduce the amount of money the franchiser will make.
If a franchiser operated the franchise themselves they may make more money as they would receive all of the profits rather than just a percentage. However, it is quite likely that the franchiser would not have the funds available to open as many stores if it did not use franchisees.