Nov. 19 (UPI) — More than 6,100 Syrians won’t lose their temporary protected status on Friday while they challenge the matter in court, a federal judge ruled.

U.S. District Court of Southern New York Judge Katherine Polk Failla issued a preliminary injunction during a virtual hearing on Wednesday.

Failla said the Trump administration likely illegally ended the protected status for more than 6,100 Syrians, but she enabled the administration to immediately appeal her decision.

Seven Syrian refugees filed the federal challenge and accused the Trump administration of arbitrarily ending their TPS protection due to “racial animus,” Newsweek reported.

Failla was appointed to the federal bench by President Barack Obama in 2013.

The International Refugee Assistance Project, Muslim advocates and the Van Der Hout law firm filed the legal challenge on behalf of the seven plaintiffs.

“The court recognized the immense harm Syrian TPS holders would suffer if the government’s plan to illegally terminate their status was allowed to take effect this week,” IRAP attorney Lupe Aguirre said in a news release.

“Thousands of people who have built their lives here would have lost their ability to live and work with authorization in the United States in just two days.”

Aguirre said many of those affected are students, parents, doctors, teachers and others who would experience “devastating repercussions” if made to return to Syria.

The nation recently ended a 14-year civil war that resulted in the overthrow of former Syrian President Bashar al-Assad in January.

Opposition leader Ahmed al-Sharaa now is the nation’s president.

Department of Homeland Security Secretary Kristi Noem on Sept. 19 announced the end of TPS for Syrians on Friday.

Noem said protection no longer is needed for many due to the end of hostilities in Syria, and the nation’s status as a source of extremism and terrorism runs counter to U.S. interests.

She also said the TPS program was overused by the Biden administration and similarly ended the protection for Venezuelans, Haitians, Hondurans, Nicaraguans and Nepalese.

The Supreme Court recently upheld ending TPS status for Venezuelans, but the other TPS moves are being challenged in federal courts.