A statewide ban on same-sex couples adopting children in Mississippi was declared unconstitutional Thursday by a federal judge, the Associated Pressreported. Mississippi was the last state in the United States to have a ban on adoption by same-sex couples.

U.S. District Judge Daniel Jordan cited the Supreme Court's marriage equality ruling in his decision. "It also seems highly unlikely that the same court that held a state cannot ban gay marriage because it would deny benefits — expressly including the right to adopt — would then conclude that married gay couples can be denied that very same benefit," he wrote.

Source: Rogelio V. Solis/AP

Jordan ordered John Davis, executive director of the Mississippi Department of Human Services, to stop enforcing the ban, effectively opening the door for LGBT couples to file adoption paperwork as soon as possible.

The legal challenge to the ban came from four couples who filed a lawsuit in 2015, joined by the Campaign for Southern Equality and the Family Equality Council, seeking to overturn it, the New York Timesreported. One of the couples who sued, Kathryn Garner and Susan Hrostowski, have been together for more than 25 years and have a 16-year-old son, Hudson.

Source: Rogelio V. Solis/AP

Following Thursday's ruling, Garner told the AP the couple planned to file adoption paperwork as early as Friday. "I am overwhelmed with joy," she said. "For us, this has been a long time in the making."

According to the Human Rights Campaign, citing information from the U.S. Census Bureau's 2011 American Community Survey, 19% of same-sex couples in the U.S. are raising children. The decision in Mississippi comes as a victory for LGBT families amidst a storm of "religious freedom" legislation, laws that effectively legalize anti-LGBT discrimination, in several states.