WELLINGTON (Reuters) - Lawmakers in New Zealand voted almost unanimously on Wednesday to change gun laws, less than a month after its worst peacetime mass shooting, in which 50 people were killed in attacks on two mosques in Christchurch.

Parliament passed the gun reform bill, the first substantial changes to New Zealand’s gun laws in decades, by 119 to 1. It must now receive royal assent from the governor general to become law.

“There have been very few occasions when I have seen parliament come together in this way, and I can’t imagine circumstances when it is more necessary,” Prime Minister Jacinda Ardern said in presenting the legislation.

Ardern banned the sale of all military style semi-automatics (MSSA) and assault rifles just six days after the March 15 shooting, and announced plans to tighten gun laws.

A lone gunman used semi-automatic guns in the Christchurch mosque attacks, killing 50 people as they attended Friday prayers.

Authorities have charged Australian Brenton Tarrant, 28, a suspected white supremacist, with 50 counts of murder following the attacks.

The new curbs bar the circulation and use of most semi-automatic firearms, parts that convert firearms into semi-automatic firearms, magazines over a certain capacity, and some shotguns.

Existing gun laws had provided for a standard A-category gun license covering semi-automatics limited to seven shots.

The bill grants an amnesty until Sept. 30 for people to surrender prohibited items. More than 300 weapons had already been handed in, police minister Stuart Nash told parliament.

The government has begun work on a second arms amendment bill it hopes to introduce in June, he said, adding that the measure would tackle issues regarding a gun registry, among others.

The government has faced criticism from some quarters for rushing through the bill. Wednesday’s dissenting vote came from David Seymour, leader of the small free-market ACT Party, who questioned why the measure was being rushed through.

Ardern said majority lawmakers believe such guns had no place in New Zealand.

“We are ultimately here because 50 people died and they do not have a voice,” she added. “We, in this house, are their voice and today we have used that voice wisely.”

Since last month’s shooting, New Zealand has tightened security and canceled several events in Auckland, its largest city, intended to commemorate ANZAC Day on April 25.

“There is no information about a specific threat to ANZAC events,” police official Karyn Malthus, said in a statement. “However it’s important that the public be safe, and feel safe, at events in the current environment.”

In 1996, neighboring Australia banned semi-automatic weapons and launched a gun buyback after the Port Arthur massacre that killed 35 people.