A law that repeals Maryland's sodomy law took effect on Thursday, October 1.

Lawmakers approved the bill earlier this year.

Maryland's Sodomy and Unnatural or Perverted Sexual Practices Act called for up to a 10-year prison sentence for anyone convicted of sodomy, which includes anal and oral sex between consenting adults.

In 2019, more than 300 violations of the law were filed in Maryland courts, according to a report given to lawmakers, the Baltimore Sun reported.

The U.S. Supreme Court in the 2003 case Lawrence v. Texas struck down sodomy laws as unconstitutional. Such laws remain on the books in 15 states.

(Related: Gay men arrested for agreeing to consensual sex under Louisiana's invalid sodomy law.)

In its testimony before state lawmakers, the ACLU of Maryland said that such laws “endanger LGBTQ people, and leave them vulnerable to employment discrimination, unfair attacks in child custody cases, and being labeled a criminal.”