— North Carolina's law allowing magistrates to refuse to perform same-sex marriages survived a challenge Wednesday when an appeals court determined that three couples weren't harmed enough to fight the state's use of taxpayer money to apply the law.

The 4th U.S. Circuit Court of Appeals dismissed their lawsuit, rejecting arguments by the couples that their status as North Carolina taxpayers gives them standing to sue. Because two of the couples are already married and the third is engaged, the law hasn't hurt their ability to wed, the judges said.

"The outcome here is in no way a comment on same-sex marriage as a matter of social policy. The case before us is far more technical, whether plaintiffs, simply by virtue of their status as state taxpayers, have alleged a personal, particularized injury for the purposes of (federal court) standing," Judge J. Harvie Wilkinson wrote in the 3-0 ruling.

The plaintiffs are considering whether seek a hearing before the full 4th Circuit or take their challenge of the law to the U.S. Supreme Court, according to the Campaign for Southern Equality.

"The fundamental question here is when a legislature acts to target a specific community, which is clearly what happened with SB2, there has to be a way to challenge a law that's based on animus and bias. And SB2 absolutely fits those criteria," the group's executive director, the Rev. Jasmine Beach-Ferrara, said in an interview.

The 2015 law allows magistrates to recuse themselves from performing marriages "based on any sincerely held religious objections." Those who file such notices are prevented from officiating at all marriages – gay and heterosexual – for at least six months.

The law also allows staffers in county register of deeds offices to recuse themselves from issuing marriage licenses, but it requires counties to make other magistrates or staffers available to handle marriage licenses and same-sex weddings in the event of recusals.

Utah and Mississippi also have laws allowing public officials to recuse themselves from performing marriages because of religious beliefs, according to a tally by the National Conference of State Legislatures.

The North Carolina plaintiffs had challenged the law's authorization of magistrates to travel between jurisdictions at taxpayer expense to perform marriages if counterparts in another area all recuse themselves. They also cited the law's provision that allowed restoration of some retirement benefits if a magistrate resigned after gay marriage became legal but was reappointed around when the recusal law took effect.

Two of the plaintiffs are from McDowell County, where all magistrates recused themselves after the state law was passed, requiring North Carolina to pay a magistrate to come several days a week from nearby Rutherford County. Only a fraction of magistrates statewide have recused themselves.

Two of the couples who sued are lesbian. The other plaintiffs are a husband and wife who won a 1978 court ruling against North Carolina magistrates who refused to perform their interracial marriage because of religious beliefs, according to court documents.

A federal judge in North Carolina ruled last year that the plaintiffs hadn't shown direct harm, nor standing to challenge the 2015 law as taxpayers. The 4th Circuit upheld the judge, describing expenditures triggered by the law as only "some token amount of funds."

The North Carolina Attorney General's Office, which defended the law before the 4th Circuit, has said the state worked hard to balance the religious beliefs of public employees and the rights of same-sex couples by authorizing taxpayer funds for the travel needed when magistrates recuse.

North Carolina's Republican state Senate leader Phil Berger, who authored the legislation, issued a statement applauding Wednesday's ruling, noting that none of the plaintiffs was prevented from marrying because of the law: "Once again, a federal court has rejected the idea that exercising one's First Amendment religious freedoms somehow infringes on others' rights."