Photo via Facebook

Botswana’s High Court voted unanimously to legalize gay sex, scrapping colonial-era laws.

The three judges said Tuesday that the laws were unconstitutional, according to the New York Times. A gay applicant who wasn’t named challenged the laws, saying they weren’t asking for people to agree with homosexuality, but to accept it. Previously, those who engaged in gay sex could face up to five years in prison. 

“Human dignity is harmed when minority groups are marginalized...” Judge Michael Leburu said while announcing the judgment, according to the Times. “Sexual orientation is not a fashion statement. It is an important attribute of one’s personality.”

Gay sex is still criminalized in over 30 countries across Africa, but Tuesday’s ruling was a step towards gay rights on the continent.