After weeks of debate and over the objection of several voting and civil rights groups, the Florida Legislature has passed a measure requiring people with felony records to pay all financial obligations from their sentencing or get these obligations excused by a judge before they can have their voting rights restored.

On Friday, in the closing hours of the legislative session, the Florida House voted 67-42 to pass an amended elections bill containing the repayment requirement. A similar bill cleared the Florida Senate a day earlier.

Politico reports that decision to add the requirements to a larger elections bill was an “11th hour” change. Previously, the requirement had been included in two standalone bills, both of which focused on implementing a 2018 ballot initiative that restored voting rights to people with felony records.

According to the Miami Herald, the bill the Senate passed requires a person to pay all “court fees, fines and restitution” before they can vote, and also sets up two ways these costs can be excused. The first option is that a judge, with the agreement of the victim of a crime, can dismiss the repayment requirement. The second option allows a judge to convert all fines, fees, and restitution into community-service hours. In the second scenario, a person would have their voting rights restored after completing the community service.

Voting rights advocates in the state say that the newly passed measure will undoubtedly limit the impact of Amendment 4, a popular 2018 ballot initiative that restored voting rights to people “who have completed all terms of their sentence, including parole or probation,” excluding those who convicted of felony sexual offenses or murder.

As many as 1.4 million Floridians were initially estimated to be eligible to vote under the amendment, which went into effect in January. It’s unclear how many people will be affected by the repayment measure.

Amendment 4 supporters say legislators have violated the spirit of what voters supported by making a person’s voting rights dependent on how much money they can afford to pay, noting that the requirement will have a disparate impact on a group that is disproportionately black and may lack employment or large incomes.

Republican legislators say the bill was a necessary clarification of the law. Amendment 4’s supporters disagree.

The fight over Amendment 4 began last year. Shortly after the amendment passed with nearly 65 percent of the vote, Florida Republicans argued that the amendment needed additional clarification from the legislature.

“I think we’re constitutionally bound to include all terms of sentence … and I think via this legislation, we are doing our constitutional obligation to define those undefined terms in the amendment,” Florida state Sen. Jeff Brandes, who sponsored the initial Senate version of the bill, said on Thursday.

Amendment 4’s supporters, however, counter that the initiative did not need clarification, and that lawmakers are merely attempting to undermine one of the biggest voting rights expansions in decades.

Local experts also say the newly passed measure is confusing and could create an extra burden on Florida’s court system.

One of the problems is that there is no single entity responsible for tracking Florida’s particularly complicated network of fines, fees, and restitution, which makes it unclear how people will be kept updated on the total amount they must repay, or how local elections officials will track who can and cannot register.

Another is that the measure doesn’t contain any information on how courts should handle the influx of people seeking to have financial obligations dismissed or converted to community service.

“If you have potentially 1.5 million people [seeking changes to their sentence], is that going to create such a backlog that each court would have to designate a judge to hear all the applications for a waiver?” Stanford Blake, a former Miami-Dade circuit court judge, told the Miami Herald.

Instead, legislators have said they expect each court to create its own process for handling these matters, and suggested that courts create special days for judges to review Amendment 4-related cases.

“Do we want one uniform system of voting where people pay their time, they get to vote again? Or do we want to just say, ‘Here we go again: Floriduh,’” Democratic state Sen. Perry Thurston said on Thursday.

After the bill passed on Friday, Amendment 4 supporters said that the measure was a step backward for efforts to reintegrate people with felony records into local communities. “We call on the Governor to side with the 1.4 million Returning Citizens and insist for better legislation,” Desmond Meade, the executive director of the Florida Rights Restoration Coalition, said in a Friday statement. “For now, we will continue to move forward in the spirit of creating a more inclusive and vibrant democracy for all by seeking to register qualified Returning Citizens in Florida.”

If the bill is signed, it is expected that civil rights groups will file legal challenges against the legislation. On Friday, the ACLU of Florida told CNN that it will “explore all options in order to ensure that the will of the people is carried out.”