BERLIN (AP) — German lawmakers have approved a bill to keep male infant circumcision legal after a regional court ruled earlier this year that the practice amounts to bodily harm.

The government proposed the law following heavy criticism of the Cologne court ruling by Jewish and Muslim groups.

Jews in particular consider male infant circumcision an ancient and essential part of their religious tradition.

The head of Germany’s main Jewish group expressed relief at the vote, which passed with 434 lawmakers in favor, 100 against and 46 abstaining.

“The circumcision law finally restores legal certainty,” said Dieter Graumann, the head of Germany’s Central Council of Jews. “What’s important for us is the political message of this law, which is that Jewish and Muslim life is still welcome here.”

Restrictions on religiously motivated circumcision would have been particularly sensitive in Germany because of the country’s persecution of Jews and other minorities during the Nazi period.

Proponents of the law, including Chancellor Angela Merkel, noted that failure to protect circumcision would have risked making Germany the only country in the world to ban a practice that Jews and some Muslims consider an ancient and essential part of their religious traditions.

The new law, passed with 434 to 100 votes, grants parents the right to authorize the circumcision of their sons by a trained practitioner.

Once the boy reaches six months of age the procedure needs to be performed by a doctor.

A second house of parliament still needs to approve the bill. The passage of the law was expected after the cabinet approved the draft in October.

A cross-party minority in Parliament had proposed that parents should have to wait until their son is 14 so he can give informed consent for the procedure.

The World Jewish Congress welcomed the move, saying the law would help protect Jewish life in Germany

“Today, representatives of all major parties have made it clear that the renaissance of Jewish life in Germany can and should continue,” WJC head Ron Lauder said in a statement. “The bitter debate that followed the Cologne court ruling on circumcision has irritated and unsettled many Jews around the world, and we hope that a clear legal basis has now been put in place that will prevent the criminalization of religious circumcision in the future.”

 Times of Israel staff contributed to this report.