A federal judge in Buffalo ruled that New York’s ban on guns in places of worship is unconstitutional, but guns will still be prohibited in churches, mosques and synagogues — at least for now.

In an order filed on Thursday in the Western District of New York, federal Judge John L. Sinatra, Jr. said the state’s new concealed carry law violates the Second Amendment, goes against U.S. Supreme Court precedent, and could cause irreparable harm to a pastor and his church.

Sinatra’s decision comes about two months after a similar decision in another case challenging New York’s Concealed Carry Improvement Act. Both rulings have been placed on hold while the state appeals, meaning that guns are still prohibited in places of worship for the time being.

Pastor Michael Spencer and his western New York congregation filed a lawsuit in November, saying he and some members want to be able to arm themselves in church. Spencer said that he has received death threats in the past and fears for his safety and that of his parishioners, given recent mass shootings at places of worship across the country.

The suit accused the state of religious discrimination, arguing that “No other state in the Union has taken the radical step of completely disarming houses of worship and stripping them of their right to decide who may carry firearms on their premises.”

This past summer, the Supreme Court struck down the state’s prior gun control laws, which had been in effect for more than 100 years. The justices ruled that New York had placed too much of a burden on permit applicants and holders and ordered the state to make it easier for people to exercise their Second Amendment rights.

Albany legislators responded by passing a host of new requirements to obtain a concealed carry permit and sweeping restrictions for people who are licensed to carry a pistol.

Since then, gun owners and Second Amendment advocates have brought at least nine lawsuits, which Gothamist is tracking. Some seek to overturn the entire law, while others object to certain parts, like the ban on guns in public transit and a requirement to list social media handles in concealed carry permit applications.

Multiple lawsuits have challenged the state’s new list of “sensitive locations,” where even permit holders are not allowed to carry pistols, other than police, active-duty military and a few other exempted groups. Several of those legal complaints, including Spencer’s and a lawsuit brought by Jewish New York City residents, have urged the state to remove places of worship from that list.

The slew of litigation has sparked a confusing back-and-forth in the courts as judges issue contradictory decisions and rules are temporarily struck down, only to be reimposed by higher courts.

In one case challenging the entire law, a judge in Syracuse declared the Concealed Carry Improvement Act unconstitutional multiple times without successfully blocking it. Two national Second Amendment groups filed an emergency motion last week, asking the U.S. Supreme Court to allow the judge’s preliminary injunction to stand.

“We urge the High Court to once again hold the state accountable for violating the Second Amendment rights of their own citizens,” Erich Pratt, senior vice president of Gun Owners of America, said in a press release last week.

The state attorney general’s office did not comment on the most recent ruling. But AG Letitia James has vowed to “defend the constitutionality of our laws to protect all New Yorkers.”

“Responsible gun control measures save lives and any attempts by the gun lobby to tear down New York’s sensible gun control laws will be met with fierce defense of the law,” James said in a statement this fall.

The state Legislature reconvenes next week. It’s unclear at this point whether lawmakers will consider any changes to the law while litigation is still pending.