The State of California has passed a controversial law decriminalizing prostitution for minors by treating them as victims, not criminals, but that has some legislators arguing that in theory, it legalizes child prostitution.

SB 1322, authored by Sen. Holly Mitchell (D-Los Angeles), was part of a series of bills Gov. Jerry Brown signed into law in that will go into effect on January 1, 2017. While solicitation and loitering with the intent to commit prostitution are misdemeanor crimes, SB 1332 bars law enforcement from charging minors — anyone under the age of 18 — with prostitution.

Thank you @JerryBrownGov for signing SB 1322 and showing that California loudly states that "There is no such thing as a child prostitute!" — Holly J Mitchell (@HollyJMitchell) September 26, 2016

SB 1332 was reportedly adopted on a floor vote of 41 to 27 before receiving Gov. Brown’s signature. Mitchell authored three other bills that address the illegal trafficking of juveniles in California, namely SB 955, SB 1165 and SB 1388; all of them were signed into law.

In an op-ed blasting SB 1332, Assemblyman Travis Allen (R-Huntington Beach) writse of the “unintended but predictable consequence of how the real villains — pimps and other traffickers in human misery — will respond to this new law.” He says that while “pimping and pandering will still be against the law,” SB 1332 “will only incentivize the increased exploitation of underage girls.”

The text of SB 1332 states:

Existing law makes it a crime to solicit or engage in any act of prostitution. Existing law makes it a crime to solicit of engage in any act of prostitution. This bill would make the above provisions inapplicable to a child under 18 years of age who is alleged to have engaged in conduct that would, if committed by an adult, violate the above provisions.

A lawyer by training, Allen credits Democrats for being “sincere in their belief that decriminalizing underage prostitution is good public policy that will help victims of sex trafficking.” However, he also notes the “immoral” consequences associated with what sees as the decriminalizing child prostitution and the misguided nature of SB 1332.

“Unfortunately, the reality is that the legalization of underage prostitution suffers from the fatal defect endemic to progressive-left policymaking: it ignores experience, common sense and most of all human nature — especially its darker side,” Allen writes.

AB 1332 also allows officers to take these minors and other sexually exploited youth into “temporary custody”, but only “under limited circumstances,” such as situations in which their lives are at risk.

Allen argues in favor of having police officers take child prostitutes into custody, in order to help these young victims escape their abusive “pimps,” writing, “[m]inors involved in prostitution are clearly victims, and allowing our law enforcement officers to pick these minors up and get them away from their pimps and into custody is a dramatically better solution than making it legal for them to sell themselves for sex.”

Last year, local and federal authorities passed similar measures. On October 21, 2015, Los Angeles County Sheriff Jim McDonnell announced that minors caught up in sex trafficking will no longer be counted as suspects, but as victims in cases handled through the L.A. County Sheriff’s Department.

One day before McDonnell’s announcement, the L.A. County Board of Supervisors passed a motion unanimously — echoing a phrase coined by child rights activists — stating, “there is no such thing as a ‘child prostitute’.” Instead, anyone under the age of 18 will now be considered a victim.

During an August 6 meeting of the Los Angeles County Board of Supervisors, Supervisor Dob Knabe — who was supportive of SB 1332 — stated, “as we all know [the bill] also contains the language that there’s no such thing as a child prostitute.”

On Thursday, the hashtag #CaliforniaDemocrats began to trend on Twitter in response to reaction both for and against SB 1332:

I am so completely disgusted. We should be working to PROTECT children, not legalize child prostitution. #CaliforniaDemocrats — #ThePersistence (@ScottPresler) December 30, 2016

I am a former child abuse prosecutor! California democrats just decriminalized being a victim of child sex traffickers! Kudos! — Sara Spector (@Miriam2626) December 30, 2016

California Democrats recognize children forced into prostitution are not criminals, but victims. Go after pimps & john's, NOT kids. — ♀️ ᵀᴴᴱ – (@Im_TheAntiTrump) December 30, 2016

So #CaliforniaDemocrats is trending because conservatives would rather treat child prostitutes as criminals rather than victims. Sick people — J-San 👨‍🏫 (@lawdood) December 30, 2016

Glad I switched parties when I did. The Democratic party is an embarrassment.

Disgusting, moral-less, cry babies.#CaliforniaDemocrats — Josh (@JoshNoneYaBiz) December 30, 2016

Allen’s op-ed has stirred a flurry of negative responses from the left. California’s Senate President Pro Tem Kevin de León tweeted, “Shame on Republicans who are twisting the facts.”

#CaliforniaDemocrats created a law to protect children who are victims of sex trafficking. Shame on Republicans who are twisting the facts. — Kevin de Leόn (@kdeleon) December 30, 2016

“Unfortunately for Californians, SB 1322 isn’t an outlier — it’s only the tip of the liberal iceberg,” Allen argues. “2017 will see the Golden State subjected to wave after wave of laws taking effect that are well-intentioned but disastrous embodiments of progressive utopianism.”

Follow Adelle Nazarian on Twitter and Periscope @AdelleNaz