Ravi Ragbir is coming home—for now.

On Monday, United States District Judge Katherine Forrest ruled that the “the government acted wrongly” and with “unnecessary cruelty” in detaining the well-known immigrant advocate during a routine check-in earlier this month, and ordered his immediate release from a correctional facility in Orange County, New York. Noting that, “there is, and ought to be in this great country, the freedom to say goodbye,” Forrest repeatedly condemned the Immigration and Customs Enforcement agency’s actions. “This abrupt and by all accounts unnecessary detention, a step in the direction of deportation, was wrong,” she declared.

News of the unexpected ruling quickly spread from the packed courtroom to the overflow room to outside the courthouse, where dozens of supporters had been marching silently in protest of Ragbir’s detention. “It was one of the most intense experiences of my life,” said Hansell Patterson, a volunteer with the New Sanctuary Coalition, where Ragbir is an executive director. “There were tears of joy because the judge really nailed it.”

“My faith in our system has been restored,” said Ragbir’s wife, Amy Gottlieb, who works as an immigration attorney. “This is beautiful—this is what our judiciary is set up to do.”

Ragbir, a 27-year resident of the United States, has long lived under the threat of deportation. Due to a wire fraud conviction in 2001, which triggered removal proceedings, his status in the country has depended on a series of temporary stays, granted because of his family ties and his work with the New Sanctuary Coalition. While he’s advocated for the undocumented community for years, since the election President Trump, Ragbir has become perhaps the most visible immigrant leader in New York—a distinction for which he fully expected to be punished under the new regime.

On January 11, Ragbir was detained during a routine check-in with ICE officers and told that he’d soon be deported to Trinidad. A chaotic scene ensued, as protesters attempted to block the ambulance transporting Ragbir, who’d briefly fainted after receiving the news. New York City police officers arrested 18 people, some violently, including City Council members Jumaane Williams and Ydanis Rodriguez.

Days earlier, another leader of the New Sanctuary Coalition, had been detained and deported over a 28-year-old drug charge, causing legal observers to warn of an ICE crackdown against the movement’s leading activists. “Ravi’s arrest is part of a disturbing pattern,” said Donna Lieberman, executive director of the New York Civil Liberties Union. “ICE is targeting immigrant advocates who dare to express dissent against the administration’s cruel deportation agenda.”

Monday’s decision does little to change that impression, or to ease the fears of the city’s faith leaders who say that unmarked ICE vans have begun surveilling their homes and worship spaces. And Ragbir is not off the hook yet either—his appeal process is ongoing, and he’s scheduled to appear in court again next month.

But according to his family and legal team, the judge’s ruling proves the grassroots opposition to ICE’s increasingly brazen deportation tactics is working. “Ultimately, we all know that it’s the community support for Ragbir that’s the reason he remains at home,” Alina Das, Ragbir’s attorney, told reporters gathered outside the courthouse. “It’s our hope that those voices will continue to be heard.”

Gottlieb, flanked by dozens of supporters, echoed that assertion: “Without the community’s support we wouldn’t be close to where we are today. Seeing this surge of love has given Ravi and me the strength to keep going, and it’s also encouraging for the movement.”

As the legal team fielded questions, Gottlieb stood outside the courthouse, making logistical plans to bring her husband home. After a few minutes of trying, she was able to get Ragbir on the phone and tell him, via speakerphone, about the judge’s order (“When, when, when, when!?” Ragbir replied). She wondered aloud if she’d be able to bring Ragbir to Trump’s State of the Union address on Tuesday, which Representative Nydia Velázquez had invited her to attend, and whether he’d even want to go. “First thing he’ll want to do is take a shower and eat some real food,” she predicted.

As Gottlieb pondered the perfect meal, dozens of supporters were piling into a fleet of cars to greet Ragbir upstate. One coalition volunteer suggested they throw a party that night. Another offered three seats in her car, all of which were quickly claimed. Led by Gottlieb and Ragbir’s legal team, the elated crowd set out to celebrate Ragbir’s victory with him in-person.

“Wait!” someone called. “Make sure we’ve got an open seat for Ravi!”