President Donald Trump’s administration slammed a San Francisco-based federal judge’s ruling Tuesday morning that states a policy requiring asylum seekers to remain in Mexico while their claims are adjudicated is not legal.

A liberal activist judge in San Francisco ruled the United States and Mexico can’t work together to address asylum issues at the border. It’s sad that Mexico is now doing more to secure our border than Democrats – President Trump will do whatever it takes to keep Americans safe. — Sarah Sanders (@PressSec) April 9, 2019

Trump also tweeted his fury with the decision Monday evening, saying:

A 9th Circuit Judge just ruled that Mexico is too dangerous for migrants. So unfair to the U.S. OUT OF CONTROL! https://t.co/XF8o3jMDle — Donald J. Trump (@realDonaldTrump) April 9, 2019

Judge Richard Seeborg ruled Monday evening that new regulations developed by the Department of Homeland Security requiring migrants claiming asylum to remain in Mexico is not legal. The ruling was made on the basis that migrants claiming asylum are not receiving the humanitarian protections available under U.S. asylum protocols. (RELATED: Sanctuary Laws Allowed Illegal Immigrant Who Tried To Kill A Cop Remain In The US, ICE Claims)

Seeborg wrote, “does the [Remain in Mexico policy] include sufficient safeguards to comply with DHS’s admitted legal obligation not to return any alien to a territory where his or her ‘life or freedom would be threatened’? In support of their motion for a preliminary injunction, the plaintiffs have sufficiently shown the answer to both questions is ‘no.'”

DHS developed the “Remain in Mexico” policy to counter current requirements known as “catch and release,” which mandates that U.S. authorities process and then release family units from Central America who are claiming asylum into that country. The families are given court dates years later to adjudicate their asylum claims.

Officials say many migrants eventually have their claims rejected in court and that by the time a final order of deportation is given down from a federal judge, migrants simply do not show up. A senior administration official characterized the loophole as “backdoor illegal immigration.”