Groups supporting the rights of transgender people filed a motion on Monday asking a U.S. judge to block North Carolina from enforcing a law that mandates bathroom access according to birth sex while the measure is being challenged.

The preliminary injunction is needed to protect transgender people from suffering irreparable harm due to the law known as House Bill 2, said the American Civil Liberties Union (ACLU), the ACLU of North Carolina, and Lambda Legal, a national advocacy group for lesbians, gays, bisexuals and transgender people.

The law, enacted in March, made North Carolina the first state to ban people from using multiple-occupancy restrooms or changing rooms in public buildings and schools consistent with their gender identity. It sparked a national debate about equality versus privacy rights and has resulted in boycotts of the Southern state by businesses, conventions and entertainers.

“H.B. 2 is causing ongoing and serious harm to transgender people in North Carolina and must be put on hold while it is reviewed by the court,” Chris Brook, legal director of the ACLU of North Carolina, said in a statement.

The organizations previously sued North Carolina Governor Pat McCrory and the University of North Carolina over the law, which they argue is discriminatory.

The governor’s office did not reply to a request for comment on Monday about the latest legal move, and university system spokeswoman Joni Worthington had no immediate comment.

U.S. District Judge Thomas Schroeder, who sits in Winston-Salem and was appointed by President George W. Bush, has been assigned to the case.

It is one of several legal and political battles over bathroom policies playing out in North Carolina and beyond.

Last week, the U.S. Justice Department and North Carolina’s governor sued each other over the state measure, which federal lawyers said violates U.S. civil rights laws. McCrory and other top Republicans in North Carolina accused the federal government of overreach.

A few days later, Obama’s Democratic administration told U.S. public schools that transgender students must be allowed to use the bathroom of their choice. Social conservatives immediately pushed back, with some state officials saying the nonbinding guidance should be challenged.

(Reporting by Colleen Jenkins; Editing by Jonathan Oatis)