The Fifth Circuit Court of Appeals has issued its ruling regarding a challenge by the State of Texas to federal guidance on emergency abortions. The court ruled that the guidance amounts to an expansion of the scope of abortion that would run afoul of state law.

The Biden administration previously issued guidance to the states indicating that hospitals receiving Medicare must provide abortions if they are necessary to medically stabilize the patients, based on the Emergency Medical Treatment & Labor Act (EMTALA) of 1986.

“When a state law prohibits abortion and does not include an exception for the life of the pregnant person — or draws the exception more narrowly than EMTALA’s emergency medical condition definition — that state law is preempted,” the guidance read, per The Texas Tribune.

Texas Attorney General Ken Paxton and two medical groups sued over the guidance, claiming it was a de facto expansion of EMTALA. In August of 2022, a district judge in Lubbock sided with the State of Texas, agreeing that the federal guidelines were, in effect, a new interpretation of EMTALA. That judge granted a temporary injunction, which was later extended.

The federal government appealed the ruling, and in a hearing last November, the Department of Justice argued that the federal guidance was meant “to ensure that the care is offered when it is required under the statute,” The Texas Tribune reported.

In its January 2 ruling, the Fifth Circuit Court of Appeals agreed with a previous lower court, ruling in favor of Texas. The appeals court determined the federal guidance could ostensibly be used to expand the scope of permitted abortions to account for conditions like mental health disorders that are not directly related to a medical emergency.

“We agree with the district court that EMTALA does not provide an unqualified right for the pregnant mother to abort her child,” Judge Kurt D. Engelhardt wrote in the decision, per The Texas Tribune. “EMTALA does not mandate medical treatments, let alone abortion care, nor does it preempt Texas law.”

Texas banned nearly all abortions in 2022, drawing a narrow exception to save the life of the pregnant person. However, due to the complexities and risks of legal repercussions, many doctors have stopped performing all abortions. Doctors in Texas could lose their license to practice and face as much as life in prison for violating the law.

Texas is at the center of the national debate about abortion. The state clarified its 2022 law last year to provide guidance to hospitals and doctors, stipulating that abortions can only be performed when the procedure is necessary to stabilize the pregnant woman and prevent her death.

The federal guidance could have created a scenario in which emergency rooms became abortion clinics, according to Alliance Defending Freedom’s senior vice president of strategic initiatives, Ryan Bangert. Bangert argued the case on behalf of the two medical groups, per TIME.

The Biden administration may appeal the decision to the U.S. Supreme Court but has not announced its plans. In the meantime, abortion, except in very limited scenarios, remains illegal in the state.