Democratic presidential candidate Elizabeth Warren called Tuesday for repealing the decades-old law criminalizing unauthorized border crossing ― the same law the Trump administration used to systematically split up families at the border last year.

Warren joins fellow 2020 contender Julián Castro and several other prominent Democrats in backing a reform that, if enacted, would give civil immigration courts exclusive legal control over immigration enforcement at the border. Under the current system, tens of thousands of migrants who cross without authorization, including some asylum-seekers, face federal prosecution in criminal courts and jail time before they get in front of an administrative judge, who decides their immigration cases.

Those facing deportation in an immigration court are not being accused of a crime. But crossing the border without authorization is also a misdemeanor punishable by up to six months in jail. Repeat offenders can be charged anywhere in the country and convicted with little more than evidence of a deportation on their record and punished with sentences ranging up to 20 years, depending on the migrant’s criminal record.

While the laws criminalizing unauthorized immigration have been on the books since 1929, they rarely faced much scrutiny from the public until the Trump administration, in a widely reviled seven-week experiment last year, used them to split up families at the border as a matter of public policy.

Prosecuting immigrant parents for the crime of illegal entry pushed them into criminal custody with the U.S. Marshals Service, leaving their now-unaccompanied children in the care of immigration authorities.

In April, Castro, the former secretary of Housing and Urban Development, became the first Democratic presidential candidate to back a repeal of the law criminalizing illegal entry.

While Warren has yet to release a comprehensive immigration platform, her campaign confirmed to HuffPost that she also now favors repealing the law criminalizing migration.

“I agree with Secretary Castro,” Warren said in a statement to HuffPost. “We should not be criminalizing mamas and babies trying to flee violence at home or trying to build a better future. We must pass comprehensive immigration reform that is in line with our values, creates a pathway to citizenship for undocumented immigrants including our DREAMers, and protects our borders.”