A federal court in Southern California halted the separation of immigrant families Tuesday night and ordered the Trump administration to reunite separated children with their parents in the next 30 days. But how the government will undo the impact of its “zero tolerance” immigration policy, which is referring all illegal immigrants for criminal prosecution, is not immediately clear.

The Trump administration has separated 2,300 children from their families since May, and those kids are now scattered across the country at shelters run under contract with the Office of Refugee Resettlement. So far, much of the work to reunify the kids with their parents has fallen to humanitarian organizations and immigration lawyers.

“Everyone seems to be very confused, not just the people who are being detained and imprisoned,” said Laura Lunn, a managing attorney at the Rocky Mountain Immigrant Advocacy Network in Colorado who is representing three mothers who have been separated from their children. “Across the board I haven’t heard anybody who has concrete next steps about how they will be reunited with their children.”

Judge Dana Sabraw of the Federal District Court in San Diego ruled all children must be reunited with their families at 30 days and children under 5 must be reunited with their parents within 14 days. All children in detention must be put in touch with their parents by phone within 10 days.

How the government will essentially undo its separation of thousands of families under its “zero tolerance policy” is not immediately clear. Separate federal agencies are holding children and parents; they are not tracked together, and they have no official way of finding each other.

The Department of Justice would not comment on whether they would appeal Tuesday’s ruling and urged Congress to address to act.

“Without this action by Congress, lawlessness at the border will continue, which will only lead to predictable results—more heroin and fentanyl pushed by Mexican cartels plaguing our communities, a surge in MS-13 gang members, and an increase in the number of human trafficking prosecutions,” a Justice Department spokesperson said.

On Wednesday, a compromise immigration bill that would have created a merit-based immigration system, provided $25 billion for a border wall, and mandated that families be kept together as their immigration cases are heard, failed in the House of Representatives, even with a last-ditch push from the president.

The Department of Health and Human services has said that 500 kids separated under the “zero tolerance” policy have been reunited with their families. The Department of Health and Human Services and Department of Homeland Security, responsible for housing separated children and adults respectively, did not immediately respond to questions about how the agencies would meet Judge Sabraw’s deadline for the rest of the children.

Since the "zero tolerance" policy of referring anyone who crosses the border illegally for criminal prosecution is still in place, the administration will likely turn to family detention. But there’s a legal snag there as well: litigation born from a 1997 court case about the mistreatment of unaccompanied minor immigrants known as the “Flores settlement” mandates that the government release children who are held in family detention after 20 days.

The Department of Homeland Security’s family detention capacity is currently 2,700 people, according to Tuesday’s ruling. Last Friday DHS filed a “request for information” on how to "provide quality and compassionate care for non-criminal families in a residential setting" for 15,000 beds.