The Department of Homeland Security said Monday that it ended a Trump-era policy requiring asylum-seekers to wait in Mexico for hearings in U.S. immigration court, hours after a judge lifted an order in effect since December that it be reinstated.

The timing had been in doubt since the Supreme Court ruled on June 30 that the Biden administration could end the “Remain in Mexico” policy. Homeland Security officials had been largely silent, saying they had to wait for the court to certify the ruling and for a Trump-appointed judge, Matthew Kacsmaryk in Amarillo, Texas, to then lift his injunction. The Supreme Court certified its ruling last week.

The program will be unwound in a “quick, and orderly manner,” Homeland Security said in a statement. No more people are being enrolled and those who appear in court will not be returned to Mexico when they appear in the U.S. for their next hearings.

The policy “has endemic flaws, imposes unjustifiable human costs, and pulls resources and personnel away from other priority efforts to secure our border,” the department said.

Many questions remain, including whether those whose claims have been denied or dismissed will get a second chance or if those whose next court dates are months away will be allowed to return to the U.S. sooner. Homeland Security said it will provide additional information “in the coming days.”

About 70,000 migrants were subject to the policy, known officially as “Migrant Protection Protocols,” from when President Donald Trump introduced it in January 2019 until President Joe Biden suspended it on his first day in office in January 2021, fulfilling a campaign promise. Many were allowed to return to the United States to pursue their cases during the early months of Biden’s presidency.

Nearly 5,800 people were subject to the policy from December through June, a modest number. Nicaraguans account for the largest number, with others from Cuba, Colombia and Venezuela.

Trump made the policy a centerpiece of border enforcement, which critics said was inhumane for exposing migrants to extreme violence in Mexico and making access to attorneys far more difficult.