Less than one year after a Desert Sun investigation revealed Indio and Coachella had hired an outside law firm to prosecute residents found in violation of municipal ordinances, then charged them thousands in “prosecution fees,” the practice has been officially outlawed in California.

On Wednesday, Governor Jerry Brown signed into law Assembly Bill 2495, prohibiting cities from charging residents the cost of legal services used to prosecute them.

The bill’s author, Assemblymember Chad Mayes, R-Yucca Valley, said he was excited to hear Brown had signed the bill and credited the Desert Sun’s investigation as the first step in the process to its enactment.

In a five-part series, The Desert Sun found Silver & Wright, an outside law firm hired by Indio and Coachella, had charged residents thousands in prosecution fees, often for minor infractions involving things like messy yards, keeping chickens on a property, and failing to apply for building permits.

SIGN UP FOR FACEBOOK NEWS ALERTS: Message us here to get started

More:They confessed to minor crimes. Then City Hall billed them $122K in 'prosecution fees'

The bill received support from civil rights groups, corporate lawyers and criminal justice reform advocates.

The Civil Justice Association of California, a group that supports tort reform and generally opposes trial lawyers, lauded the bill.

“This arrangement has evolved into a for profit-scheme where law firms are aggressively marketing themselves to cities to prosecute code violations and insisting cities rewrite local codes to explicitly provide for recovery of fees,” they wrote in a letter to the Assembly Public Safety Committee

In another support letter, Gareth Elliott and Nick Brokaw, lobbyists for the California Public Defenders Association, called the practice an example of “how corrosive monetary interests can be on the criminal justice system.”

But the League of California Cities and the California Association of Code Enforcement Officers began lobbying against the bill, claiming it infringed upon local control and hindered cities’ abilities to enforce their municipal codes.

More:Bill banning ‘prosecution fees’ unanimously passes California Assembly

More:She was fined $5,600 for a few chickens. Now she is suing to end ‘prosecution fees’ in Indio and Coachella.

In a letter to Mayes, John Lovell and Dan Carrigg, lobbyists for the two groups opposing the bill, wrote that limiting cities from charging prosecution fees would empower people who repeatedly violated municipal codes, such as slumlords, and impose an undue financial burden on city budgets.

“When prior notices and other efforts to get voluntary compliance fail, a city’s most effective and quickest tool to gain compliance and protect occupants is criminal prosecution,” Lovell and Carrigg wrote, defending the practice.

In June, after the State Senate Public Safety Committee considered the bill, Mayes added several amendments to clarify that the scope of the bill was limited to city ordinances and didn’t apply to probation departments charging cost recovery fees.

In August, a majority of Democrats and Republicans in both the Senate and Assembly voted in favor of the bill, sending it to the Governor Brown’s desk to be signed.

Rather than dividing politicians along partisan lines, AB 2495 exposed a conflict between city officials and state legislators.

Mayes and Assemblymember Eduardo Garcia, D-Coachella, who co-authored the bill, discussed the code enforcement practice in front of local business leaders and politicians at a legislative update event hosted by the Greater Coachella Valley Chamber of Commerce. With a League of Cities representative and city government officials in the audience, including from Indio and Coachella, Mayes alluded to the pushback the bill generated among city officials.

“The League of Cities was not exactly thrilled with me on (AB 2495) and I got a few phone calls from a couple of city council members, but, I’ll tell you, it was right, it was just,” Mayes said.

He called the practice “policing for profit” and said it was inappropriate and unethical.

Echoing Mayes, Asm. Garcia said taking residents to criminal court for minor infractions, then charging them for the cost of the prosecution imposed an undue burden on low-income residents.

“We don’t want to see people ending up in court charged with criminal charges and then ultimately having to pay those fees to attorneys or law firms prosecuting on behalf of cities,” he explained.

Both Mayes and Garcia began their political careers in local government and said the pushback from Coachella Valley city officials and the League of California Cities stemmed from concerns about the state imposing restrictions on cities.

“It’s a local control issue,” Garcia said. “We’re impeding on their ability to do what they need to or want to do.”

Mayes said he often advocates for local control but saw no problem with the state limiting local government’s ability to charge its residents prosecution fees.

“I am a strong believer in local governance,” Mayes said, “but you got to put controls, not only on the governed but on those who govern. It’s absolutely appropriate for state government to put restraints on other governments so they can't take life, liberty, or property away from folks.”