A British government minister has criticized the London authorities for deciding to strip Uber of its taxi license, a major setback to the U.S. technology firm that has become a big player in the city’s transport system.

The British capital’s transport regulator deemed Uber unfit to run a tax service and said its license would not be renewed when it expires Sept. 30. London Mayor Sadiq Khan, a member of the opposition Labour Party, backed the move.

“At the flick of a pen Sadiq Khan is threatening to put 40,000 people out of work and leave 3.5 million users of Uber stranded,” Greg Hands, the government minister for London, wrote on Twitter late on Friday.

He said Uber had to address safety concerns and it was important that there was a level playing field across the private hire market.

In backing the decision to strip Uber of its license, Khan said: “All private-hire operators in London need to play by the rules. The safety and security of customers must be paramount.”

Uber has said it will contest the decision. Regulator Transport for London (TfL) said it would let Uber operate until the appeals process is exhausted, which could take months.

Uber has turned to customers to help defend itself in other battles around the world, and an online petition to support Uber in London gathered nearly 430,000 signatures by early Saturday.

In Friday’s announcement, TfL cited concerns about Uber’s approach to reporting serious criminal offenses, background checks on drivers and software that could be used to block regulators from gaining full access to the app.