Given the choice between a private contract and government legislation, most companies would likely choose private contracts.
IANAL or a historian but from other discussions I read, I got the impression that, at the time, contract law wasn't as advanced as it is today. That's likely why it took a law to clear the way for franchises.