The following op-ed was co-authored by R Street Texas Director Josiah Neeley.

Rarely has the effect of a vote been felt so quickly. Austin citizens voted May 7 not to block restrictions on ridesharing companies passed by the City Council the previous December. Within two days of the vote, both Uber and Lyft (the two major transportation network companies, or “TNCs”) had ceased operations in the city, claiming the new rules—which included a requirement to have already run fingerprint checks on at least 25 percent of their drivers by voting day—were forcing them out.

By all accounts, this was not a result either side wanted. Austin Mayor Steven Adler said both before and after the vote that he hoped the city could come to an understanding with Uber and Lyft that would allow them to remain. The mayor had hinted that the phase-in of fingerprint requirements could be delayed, although the recent city ordinance requiring them remained on the books. The companies themselves can’t be pleased with having to leave a previously thriving, successful market.

Yet what no one wanted (except the Big Three incumbent taxi companies) is precisely what happened. Given that fights like these already are breaking out in other cities, it’s worth considering what lessons both cities and other sharing-economy companies can learn from how Austin’s ridesharing experiment unraveled.

For the companies, the chief lesson is that politics is a very different business than business itself. This is particularly true when it comes to making your case before the public. Tech companies often make the mistake of thinking their services are so self-evidently valuable that the general public will automatically flock to their banner. Yet many voters who were bombarded by flyers, ads and other media have never actually used a ridesharing service. Even those who have may have other concerns.

Companies also are vulnerable to attacks that characterize them as “big greedy corporations,” particularly when they spend a lot of money advocating their point of view. By the end of the TNCs’ public campaign backing Proposition 1, opponents were talking almost exclusively about the money that was spent and hardly at all about the substantive policy issues.

Superior economic resources can leave one to be labeled a “bully.” That word was thrown around a lot in Austin, even though the opposition’s success strongly suggests bigger companies aren’t always stronger political players. Companies need not deny that their proposals benefit them financially. But they need to show they serve other interests besides the bottom line. In Austin, ridesharing companies could have said outright that part of their business model – including their opposition to a flawed FBI-centric fingerprinting process that would have a disproportionate impact on some minority applicants – includes having a more diverse, more gender-balanced workforce of drivers, something that burdensome fingerprinting requirements would have made difficult to achieve. That might have put opponents in the position of having to explain the composition of the taxi workforce.

Most importantly, companies need to be able to adapt quickly to the realities on the ground. A more nimble campaign in Austin would have adjusted to the changing narrative, as the opposition found its talking points. It could have channeled the voices of the NAACP and Austin’s Urban League, who could have explained straightforwardly the racial impact of an emphasis on FBI fingerprint records. The TNCs would have done better to make particular well-known Austinites, or even newcomer advocates like those who built ATXSafer Streets, the public faces of their campaign.

Cities, too, have a lot to learn. First, don’t regulate just for the sake of regulating. Austin’s new ridesharing regulations lacked any plausible rationale. The bare handful of assault complaints against ridesharing drivers—and taxi drivers—ultimately had resulted in only one conviction, and it was of a taxi driver. Existing regulations were working fine. There was no public outcry or incident demanding a shake-up. Indeed, it was the new regulations that sparked a backlash, with both the public and top law-enforcement officials speaking out about the value ridesharing provided to the city. Most of this fell on deaf ears. It seemed clear during public testimony on the ordinance in December that the City Council had already made up its mind.

City governments also need to be prepared for how others respond to their rules. City officials seemed to be in denial about the likelihood that Uber and Lyft would leave the city if the new rules were implemented, even though the companies had followed through on that promise in other cities—often with the effect of moving the cities back to the negotiation table. It’s shortsighted to ignore the risk that, when government imposes new restrictions on business, a business may decide it’s just not worth it to stay

Austin also seemed unprepared for how much interest the controversy would garner beyond the city limits. The new ordinance has generated loads of bad press that risks damaging Austin’s brand as a tech-friendly metropolis. A traditionally left-of-center city, Austin may find itself in the position of inviting intervention from a Republican-dominated Legislature. State lawmakers already have pledged to pre-empt Austin’s new rules during next year’s legislative session.

Finally, both cities and companies can take solace that you can correct your mistakes if you act quickly enough. When San Antonio passed a fingerprint requirement in 2014, both Uber and Lyft left town. But after extensive negotiation and reconsideration, the city was able to compromise, instituting a voluntary fingerprinting requirement that all sides could live with.

There’s still time for Austin to do something similar before the Texas Legislature convenes this coming January, and activist legislators follow through on the threat to take ridesharing regulation out of the city’s hands.