A federal judge on Thursday restored early voting days in Ohio ahead of this November’s midterm election.

The decision is a win for voting rights advocates in Ohio, who say cuts to early voting days discriminate against black and minority voters. “This ruling will safeguard the vote for thousands of Ohioans during the midterm election,” said Dale Ho, director of the American Civil Liberties Union’s Voting Rights Project.

In February, Ohio passed a new voting law that cut an early voting period known as “Golden Week” where residents could register and vote on the same day. The Ohio Secretary of State also cut early voting on Sundays and restricted evening hours. The state’s election officials had reportedly recommended the early voting period be cut in order to clearly distinguish the periods for voter registration and casting ballots.

The ACLU and the ACLU of Ohio challenged the measures in May, and the resulting ruling will restore evening voting hours, some Sunday voting, and the “Golden Week.”

Voting rights advocates have called the cuts to early voting racially discriminatory. In 2012, 157,000 Ohioans voted during the early voting days that were eliminated, many of whom were black, according to the ACLU’s complaint. In Ohio’s County Cayahoga, its most populous, black voters cast 56% of early weekend ballots in 2008, though they make up 28% of the county’s population.

Ohio Secretary of State Jon Husted said he had set uniform voting hours so as to avoid “disparity in access” to the ballot box. “Today’s ruling kicks the door open to having different rules for voting in each of Ohio’s 88 counties, which is not fair and uniform and was not even acceptable to this court or the plaintiffs previously,” he said in a statement, adding that the state would appeal the ruling.

Attorney General Eric Holder called the decision a “a milestone in our effort to continue to protect voting rights” in a statement Thursday, noting that it “rests on some of the same legal reasoning” as pending Department of Justice challenges to voting laws in Texas and North Carolina.

The DoJ and civil rights groups have pledged to fight in court voting laws deemed to be restrictive, in the wake of the Supreme Court’s decision to strike down a portion of the Voting Rights Act that required states with a history of suppressing the votes of minorities to get federal approval before enacting new election laws. That portion of the Voting Rights Act did not cover Ohio.

Contact us at letters@time.com.