The Trump administration on Thursday filed papers at the U.S. Supreme Court backing a Christian baker in Colorado whom a state court ruled against for declining to make a wedding cake for a gay couple.

In the brief, Acting Solicitor General Jeff Wall said Jack Phillips should be exempt from Colorado’s anti-discrimination law because making custom cakes is a form of free expression protected under the U.S. Constitution’s First Amendment.

The high court agreed in June to hear Phillips’ appeal of the state court ruling that his refusal to make the cake violated the anti-discrimination law.

Phillips contends the law violated his constitutional rights to freedom of speech and free exercise of religion.

The court will hear oral arguments and issue a ruling in the case in its new term, which starts in October and ends in June.

The legal fight broke out in 2012 when Phillips told gay couple David Mullins and Charlie Craig that because of his Christian beliefs, his store’s policy was to deny service to customers wanting to purchase cakes to celebrate a same-sex wedding.

In the new court papers, Wall wrote that a First Amendment violation occurred “where a public accommodation law compels someone to create expression for a particular person or entity and to participate, literally or figuratively in a ceremony or other expressive event.”

Wall said if Phillips wins the case, only businesses that engage in creative acts similar to making a cake would potentially be able to obtain similar exemptions from anti-discrimination laws.

“What the Trump administration is advocating for is nothing short of a constitutional right to discriminate,” said American Civil Liberties Union lawyer Louise Melling, who represents the couple.

In recent months, the Trump administration has taken several legal and political positions to limit the rights of gay, lesbian and transgender people, sharply reversing policies of former President Barack Obama.

In August, Trump signed a memorandum directing the U.S. military not to accept transgender men and women as recruits and halting the use of government funds for sex-reassignment surgeries for active personnel unless the process had already started.

The administration previously revoked landmark guidance to public schools saying transgender students should be able to use the bathrooms of their choice. In July, it told a U.S. appeals court that federal law does not ban discrimination against gay employees.