Bermuda's Supreme Court legalized same-sex marriage on Wednesday, striking down an attempt by the island's legislature to define marriage as a union between a man and a woman.



It is the second time in just over a year that the high court has ruled in favor of same-sex marriage. In May 2017, Bermuda's Supreme Court ruled that defining marriage as a union between a man and a woman discriminates against same-sex couples.



But Bermuda's parliament sought to reverse the court's 2017 ruling by passing a law called the Domestic Partnership Act, which again restricted marriage to unions between men and women.



The Supreme Court's decision on Wednesday threw out the provisions of the law that effectively banned same-sex couples from getting married.



The legal battle in Bermuda drew in the cruise line Carnival Corp, which is registered in the island. The Domestic Partnership Act had prevented the company from conducting same-sex marriages aboard its ships anywhere in the world.



Carnival Corp provided "financial, public relations and civic" support to OUTBermuda in its efforts to challenge the island's same-sex marriage ban.



OUTBermuda hailed Wednesday's Supreme Court ruling as a "historic decision."



"Our hearts and hopes are full, thanks to this historic decision by our Supreme Court and its recognition that all Bermuda families matter," OUTBermuda said in a press release. "Equality under the law is our birthright, and we begin by making every marriage equal."