A Republican from Hartford has said that businesses should be allowed to discriminate against people of colour, after a court ruling backed a bakery that refused to make a cake for a same-sex weeding.

Michael Clark posted the comments on Facebook, shortly after the US Supreme Court decided that the state of Colorado violated ‘religious freedom’ protections by ordering bakery owner Jack Phillips to cease discriminating against same-sex couples.

LGBT rights campaigners have slammed the ruling.

In now-deleted comments under a news story about the decision, reports Argus Leader, the South Dakota lawmaker wrote: “He should have the opportunity to run his business the way he wants.

“If he wants to turn away people of color, then that(‘s) his choice.”

He described the ruling as a “win for freedom of speech and freedom of religion.”

Clark has since apologised for his remarks, after they were widely reported, posting a statement on his Facebook page.

“I made some comments here on Facebook, defending a Colorado Baker decision not create a cake for a Homosexual wedding. The comments I made were very racist,” he wrote.

“I would like to apologize for those comments. Businesses should not be able to discriminate solely based on race, sex, national origin, age, or handicap.

My comments were made in haste, with the belief that businesses should be able to operate with fewer constraints of a heavy-handed government. Of course, I was wrong, all business should serve everyone, equally.”

The US Supreme Court ruled 7-2 in favour of Phillips’ Masterpiece Cakeshop.

Phillips had launched a legal challenge to state anti-discrimination laws after refusing to serve gay couple David Mullins and Charlie Craig.

The baker refused to make a cake for the couple after he found out they were celebrating their wedding.

Phillips claimed that Jesus Christ would discriminate against gay people, and insists his religion requires discrimination against gay people.

The Colorado Civil Rights Commission (CCRC) had ordered him to “cease and desist from discriminating against same-sex couples by refusing to sell them wedding cakes or any product [they] would sell to heterosexual couples.”

But the US Supreme Court issued a ruling on Monday overturning that order. The narrow opinion largely shies away from setting a wider precedent of what discrimination is permissible in the name of religious freedom, though it did find that the actions of the CCRC were discriminatory.

The justices ruled that the CCRC “showed elements of a clear and impermissible hostility toward the sincere religious beliefs motivating his objection.”

The majority opinion led by Chief Justice Kennedy states: “The Colorado Civil Rights Commission’s consideration of this case was inconsistent with the State’s obligation of religious neutrality.

“The reason and motive for the baker’s refusal were based on his sincere religious beliefs and convictions.”

Kennedy added: “When the Colorado Civil Rights Commission considered this case, it did not do so with the religious neutrality that the Constitution requires.

“It is proper to hold that… the Commission’s actions here violated the Free Exercise Clause; and its order must be set aside.”

The justices avoided setting a wider precadent in favour of religiously-enabled discrimination, however, finding that gay people were entitled to equal protection under the law.

They said: “The outcome of cases like this in other circumstances must await further elaboration in the courts, all in the context of recognizing that these disputes must be resolved with tolerance, without undue disrespect to sincere religious beliefs, and without subjecting gay persons to indignities when they seek goods and services in an open market…The judgment of the Colorado Court of Appeals is reversed.”

Pro-LGBT law firm Lambda Legal lamented: “This 7-2 ruling, while limited, invites discrimination and further efforts to justify withholding service from LGBTQ people. This will encourage all sorts of mischief by well-funded anti-LGBTQ organizations who want to create exceptions to nondiscrimination laws.

“We’re going to see years of needless, hurtful litigation by those seeking to evade responsibility for discriminating against members of our community.

“The Court today has turned its back on longstanding precedent and offered not just encouragement but a roadmap to those who would deny civil rights to LGBTQ people and people living with HIV.

“Religious freedom under our Constitution has always meant the right to believe whatever you wish. NOT to act on your beliefs in ways that harm others.

“SCOTUS has become an accomplice in the right’s strategy to hollow out one of its finest achievements, the right to equal marriage, and create what Justice Ginsberg memorably termed ‘skim milk marriages.’

“We are ready to fight back and make sure this heartbreaking and infuriating decision is understood for what it is: a narrow ruling limited to unique facts that cannot be used to justify discrimination in any other context.

“We will continue to fight in every arena and in every court until LGBTQ people and people living with #HIV have full equality under the law in every aspect of our lives. We deserve no less.”