Keith Ellison has joined 21 other attorneys general working to preserve the protected status of thousands of immigrants allowed to live and work in the United States.

Supporters of the program say federal efforts to strip those protections are discriminatory and would endanger thousands of people while disrupting local economies.

Ellison signed on to an amicus brief asking the Ninth U.S. Circuit Court of Appeals to uphold a lower-court injunction blocking Homeland Security from terminating Temporary Protective Status for people from Haiti, El Salvador, Nicaragua and Sudan. The Attorney General’s Office said Minnesota is believed to have between 5,000 to 10,000 people from various countries who hold TPS.

“Thousands of Minnesotans are able to live here in peace and work to afford their lives and live with dignity because TPS has protected them from being deported to countries that are in the throes of war, conflict, and natural disaster,” Ellison said in a statement on Monday.

TPS is provided to foreign nationals whose countries of origin are deemed unsafe. In October, a federal judge in California granted a preliminary injunction requested by a group of plaintiffs that included children who are citizens, their noncitizen parents and other TPS recipients who alleged that the government’s new TPS policies did not follow legal requirements and was discriminatory in its intent.

The amicus brief Ellison joined is asking the Ninth Circuit to uphold the district court’s injunction pending the final outcome of that case. Ellison’s office said the Trump administration’s new policy of evaluating whether it is safe for TPS holders to return to their home countries ignores “other intervening conditions that pose a series of threats” to the TPS holders’ safety.

“Already, TPS terminations are hurting our economy and civil society, as the prospect of widespread removal has left whole communities uncertain, confused, and afraid,” according to the brief Ellison co-signed.

The court filing, also commonly referred to as a “friend of the court” brief, is the latest multistate legal action joined by Ellison since taking office last month. Ellison also joined a legal effort to block the government from adding a citizenship question to the 2020 Census, and he said he considered taking legal action during the recent partial government shutdown.