The city of Philadelphia will pay more than $200,000 to a group of Chinese restaurant owners who claimed police targeted them by selectively enforcing an ordinance that required certain businesses to close at 11 p.m.

In the settlement, filed Thursday in federal court in Pennsylvania’s Eastern District, the city agreed to stop enforcement of the code, which mandated that businesses on residential blocks in Philadelphia cease operation between 11 p.m. and 6 a.m.

Police officers will also receive additional training in implicit bias and on how to communicate with residents who are limited in their English proficiency.

Margaret Fung, executive director of the Asian American Legal Defense and Education Fund, which helped represent the 23 owners who filed suit in November, praised the terms of the settlement.

“We are glad that the City of Philadelphia has agreed not to enforce this problematic 11 p.m. ordinance,”she said in a statement. “We are also pleased to have secured some compensation for the hardship and indignity experienced by this group of immigrant small business owners with limited resources, little political power, and the additional challenges of limited English proficiency.”

Mike Dunn, a city spokesman, said it does not admit any liability in the case and decided to settle to avoid the cost of protracted litigation. The city will pay the restaurant owners a total of $265,000.

“The City of Philadelphia remains committed to protecting the ideals of equality, diversity and the protection of the rights of all citizens, and does not tolerate discrimination in any form,” Dunn told NBC News in an email.

The Asian American Legal Defense and Education Fund, along with Pepper Hamilton LLP, a law firm which took on the case pro bono, filed the suit in November.

The complaint alleged that much of the testimony in support of the ordinance, when it was proposed in the 2000s, focused on Chinese residents and their take-out restaurants. The City Council said the law was necessary “to decrease criminal activity at late-night commercial establishments and promote a feeling of safety” on residential blocks, according to court papers.

But the plaintiffs argued that the code was discriminatory and was selectively enforced.

The suit said around 96 percent of tickets for fiscal year 2015 were issued to Chinese take-out restaurants and at least 85 percent for fiscal year 2016. An updated analysis from AALDEF put those percentages even higher.

The organization also found that out of more than 1,000 tickets written for violating the 11 p.m. ordinance during the four fiscal years since 2015, at least 96.5 percent were handed to owners of Chinese restaurants.

Even Chinese restaurants on commercial blocks not covered by the ordinance repeatedly received summonses in many cases, according to the fund.

Meanwhile, pizza parlors and other fast-food eateries near some of the cited Chinese restaurants were among those permitted to stay open past 11 p.m. without receiving tickets, the complaint alleged.

Restaurant owners in the lawsuit claimed their businesses faced total fines upwards of $1,000 a piece. Three said they had to shutter their establishments, while two had to sell them off because of the enforcement of the ordinance.

Ling Lin, one plaintiff who was forced to close her restaurant and move, said Chinese restaurant owners want the laws to be enforced fairly.

“We are often treated like foreigners in our own neighborhoods, but we just want to be treated like part of the community,” she said in a statement. “And we don’t want anything like this to happen again to anyone or any other group.”

Follow NBC Asian America on Facebook, Twitter, Instagram and Tumblr.