The Kentucky state Supreme Court on Thursday ruled in favor of a Christian business owner who declined to serve an LGBT pride festival, and who was punished by a local government for discrimination.

“Today’s decision makes clear that this case never should have happened,” said Jim Campbell, senior counsel with the group Alliance Defending Freedom who argued the case of print shop owner Blaine Adamson before the Kentucky Supreme Court.

“The First Amendment protects Blaine’s right to continue serving all people while declining to print messages that violate his faith,” Campbell said.

The case of Lexington-Fayette Urban County Human Rights Commission v. Hands On Originals dates back to 2012, the print shop Hands On Originals--owned by Blaine Adamson—was asked by the Gay and Lesbian Services Organization to print shirts promoting the Lexington, Kentucky, Pride Festival.

Adamson declined, saying that to print shirts promoting such a festival would violate his Christian beliefs. He referred the organization to other vendors who could serve them.

“I will work with any person, no matter who they are, and no matter what their belief systems are,” Adamson told reporters after oral arguments in his case before the Kentucky Supreme Court, on Aug. 23. “But when I’m presented with a message that conflicts with my faith, that’s just something I cannot print.”

In 2014, the Lexington-Fayette Urban County Human Rights Commission ruled that Adamson had violated the city’s anti-discrimination ordinance. The commission required him to receive diversity training.

Adamson challenged the decision and won in a Kentucky court in 2017. The case was appealed to the state supreme court, which ruled in Adamson’s favor on Thursday.

The city’s human rights commission “lacked statutory standing” to make a discrimination claim against Hands On Originals, the court’s opinion by Justice Laurance VanMeter stated, as the complaint was brought by an organization and not an individual.

While Adamson had inquired about the nature of the festival he was requested to print shirts for, he did not ask about the sexual orientation of the organization’s representatives, the court found.

Furthermore, when the Gay and Lesbian Services Organization then filed a complaint with the Lexington Human Rights Commission, “the record is clear that no individual claimed Hands On had discriminated,” the court’s opinion said.

The city ordinance in question bars discrimination against individuals, the court said, yet “in this case, because an ‘individual’ did not file the claim, but rather an organization did, we would have to determine whether the organization is a member of the protected class, which we find impossible to ascertain.”

A concurring opinion by Justice David Buckingham, however went further in saying that the city’s human rights commission actively tried to “compel” Hands On Originals “to engage in expression with which it disagreed.”

“Hands On was in good faith objecting to the message it was being asked to disseminate,” Buckingham wrote. Citing the Supreme Court’s decision Janus v. AFSCME, he wrote that “[w]hen speech is compelled…, individuals are coerced into betraying their convictions. Forcing free and independent individuals to endorse ideas they find objectionable is always demeaning.”

Adamson’s case is one of a number of religious freedom cases where business owners have been sued for refusing to violate their religious beliefs and provide a service they deem objectionable.

Washington state florist Barronelle Stutzman has appealed to the Supreme Court after she was sued for declining to serve a same-sex wedding, and lost her case at the state’s supreme court. Colorado cake artist Jack Phillips has once again been sued for conscientiously declining to make a cake; in the most recent case, he was asked to make a cake celebrating a gender transition.