The high court of Botswana struck down the country’s anti-LGBTQ laws.

It was a unanimous decision from the three judges, according to BBC. Judge Michael Elburu called the laws “discriminatory.”

"Human dignity is harmed when minority groups are marginalized," he said. "Sexual orientation is not a fashion statement. It is an important attribute of one's personality."

The laws instituted in 1965, while the south African country was under British colonial rule. CNN reports prior to the decision, section 164 declared any person with "carnal knowledge of any person against the order of nature," faces a maximum of seven years in prison. Under section 167, “acts of gross indecency" carried a maximum of two years imprisonment.

The court intervened after 21-year-old Letsweletse Motshidiemang challenged the law in March, citing changing attitudes about homosexuality, according to local publication Tswana Times.

“Being a homosexual is not something new in my life, it is something, that I have learnt to live with growing up since the age of ten (10),” said the University of Botswana student.

“I am in a sexually intimate relationship with a man. I have no doubt that this will be the case for the rest of my life," the student continued. "My friends, roommates at the University of Botswana have accepted me, even at the University of Botswana I feel free and accepted.”

Motshidiemang claimed the laws made it hard for him to truly enjoying his life.

“By virtue of one or more of these provisions of the law, I am prohibited from expressing the greatest emotion of love through the act of enjoying sexual intercourse with another consenting adult male that I am sexually attracted to and who is also sexually attracted to me, as consenting adults,” Motshidiemang continued.

The court’s decision is a relief for the country’s LGBTQ population.

"Before we were struggling. People have been hiding," said Anna Mmolai-Chalmers, coordinator of LGBTQ rights organization Legabibo.

"This judgement can make a massive change for our lives. This is what excites me the most. The judgement means so much… The court has upheld our dignity, our privacy, and our liberty… It means freedom.”