Turkey’s government on Tuesday scrapped a proposal that critics said would have allowed men accused of sexually abusing underage girls to go free if they were married to their victims.

The proposal, which had provoked a public outcry, was scheduled to undergo a final vote in parliament Tuesday. It would have deferred sentencing or punishment for sexual assault of minors in some cases, including when the victim and the perpetrator were married.

Hours before the vote, Prime Minister Binali Yildirim said the government had withdrawn the bill to submit it to a review by a parliamentary committee. But Justice Minister Bekir Bozdag later said the proposal had been shelved and would come back on the government’s agenda only if all parties in parliament reached a consensus.

“The issue has been closed,” Bozdag said.

The age of consent in Turkey is 18, although courts permit civil marriages for people as young as 16. Many boys and girls younger than that are married in Islamic ceremonies.

The government has argued for the need to redress “unfair treatment” of families in which men were placed in jail for marrying girls younger than 18 even if both parties and their parents had consented.

The proposal by the ruling Justice and Development Party, rooted in Turkey’s Islamic movement, would have applied to cases that had occurred between 2005 and Nov. 16 of this year. The measure would have required men married to minors in Islamic ceremonies to formalize their union with civil marriages.

Critics argued that the bill amounted to a pardon for statutory rape and would disrupt efforts to prevent child marriages and the sexual assault of children. They maintained that it would, for example, legitimize the practice of men taking brides as young as 13 or 14.

Opposition parties, rights groups and citizens had widely condemned the proposal since its initiation last week, issuing statements and staging demonstrations in a number of cities.

Also Tuesday, Turkey’s government dismissed an additional 15,000 people from the military, police and the civil service as part of an investigation into a failed coup attempt in July.

The government also shut down about 500 associations, 19 health establishments and nine media outlets.

Turkey has accused U.S.-based Muslim cleric Fethullah Gulen of masterminding the coup attempt and has launched a large-scale crackdown on his followers and institutions said to be run by his movement. Authorities have arrested close to 38,000 people and purged more than 100,000 others from government jobs.