Undocumented asylum-seekers who are detained near the American border do not have the right to challenge expedited deportation orders in federal court, the Supreme Court ruled Thursday.

In a 7-2 ruling in Department of Homeland Security et al v. Thuraissigiam, Justice Samuel Alito wrote in the majority opinion that “asylum claims threatened to overwhelm the immigration system,” according to the New York Times. Alito’s ruling said “Congress was entitled to respond to that crisis, (Alito) wrote, by enacting a law that limited the role federal courts may play in reviewing summary determinations of whether asylum seekers faced a credible fear of persecution were they returned to their home countries.”

Deportation proceedings typically are drawn out over months if not years, which allow the immigrants to challenge the orders. But expedited removal condenses that timeline to weeks. Vox reported that “President Donald Trump has sought to vastly expand US Immigration and Customs Enforcement’s power to use expedited removal as a means of deporting any immigrant who has lived in the US for up to two years, potentially affecting an estimated 20,000 people.”

Justices Sonia Sotomayor and Elena Kagan wrote in their dissenting opinion that asylum-seekers "who challenge the procedures used to determine whether they may seek shelter in this country or whether they may be cast to an unknown fate" deserve Constitutional protection, and that Thursday’s ruling "increases the risk of erroneous immigration decisions."

The ruling worries immigration advocates, who say it strips due process from asylum-seekers and could exacerbate cases where vulnerable legal residents are racially profiled and caught up in deportation proceedings.

“That decision is pretty devastating for people who care about immigrants’ rights and for immigrants themselves,” said Elora Mukherjee, director of Columbia Law School’s Immigrants’ Rights Clinic, in a phone interview. “The ruling fails to live up to the Constitution's fundamental protection and principle that individuals who are deprived of their liberty should have their day in court. And the decision includes and applies to asylum seekers.”

The ruling also bolsters the Trump administration’s hardline immigration policies, experts said.

“Trump has made it very clear that ICE has the authority to use this process throughout the entire country,” Boston College Law School professor Kari Hong told Vox. “They could start stopping anyone at any time on any suspicion that they have committed an immigration violation and deport them. I don’t think it’s unreasonable [to predict] that ICE agents will target dark-skinned individuals.”

The Trump administration earlier this week issued a presidential proclamation that will deny entry to the United States to four major “nonimmigrant” visa categories as well. Last week, the Supreme Court ruled against the Trump administration’s attempt to overturn the Obama administration's Deferred Action for Childhood Arrivals program, which gave the children of undocumented immigrants the right to stay in the country.