The Dutch upper house, the Senate, this week rejected a bill that would have banned the ritual slaughter of animals and had been criticized by both Muslim and Jewish groups.

The bill, proposed by the small Party for the Animals, stipulates that livestock must be stunned before being slaughtered, contrary to Muslim halal and Jewish kosher laws, which require animals to be conscious.

The lower house of parliament passed the bill a year ago, leaving a loophole saying religious groups could continue ritual slaughter if they proved it was no more painful than other methods of slaughter.

Earlier this month, the Dutch government and the Jewish and Muslim communities in the Netherlands reached an agreement that asserted that animals could continue to be ritually slaughtered as long as they lost consciousness within 40 seconds of their throats being cut. After that period they would have to be stunned.

But the Senate rejected the bill on Tuesday by 51 votes to 21, meaning it cannot become law.

Dutch Muslims, mostly of Turkish and Moroccan origin, had complained they felt stigmatized by the measure.

European Union regulations require animals to be stunned before slaughter but allow exceptions for ritual slaughter, which the European Court of Human Rights has ruled is a religious right.

The Rabbinical Center of Europe (RCE) lauded the decision by the Upper House of the Dutch Parliament.

Rabbi Binyomin Jacobs, a prominent member of RCE and chief rabbi of the Inter-Provincial Rabbinate in Holland, expressed satisfaction after the vote. “The vote in the Dutch Senate is a victory for tolerance and common sense,” said the rabbi, who played a prominent role in the agreement.