Fraser Anning had blamed the country's immigration policy which 'allowed Muslim fanatics' to migrate to New Zealand.

An Australian senator was censured by his colleagues on Wednesday for seeking to blame the victims of last month’s mosque shootings and vilify Muslims.

Sen. Fraser Anning was the target of widespread condemnation for blaming the attack in New Zealand on immigration policies. He faced more criticism later for physically striking a teenager who cracked a raw egg on his head in a viral incident in Melbourne.

Also Read New Zealand mosque shooter a white supremacist angry at immigrants

Anning came under blistering criticism over tweets within hours of the massacre, including one that said, “Does anyone still dispute the link between Muslim immigration and violence?”

“The real cause of the bloodshed on New Zealand streets today is the immigration program which allowed Muslim fanatics to migrate to New Zealand in the first place,” he said in a later statement.

On Parliament’s second sitting day since the March 15 attack in which 50 people died, government and opposition lawmakers moved the censure motion against Anning for divisive comments “seeking to attribute blame to victims of a horrific crime and to vilify people on the basis of religion, which do not reflect the opinions of the Australian Senate or the Australian people.”

“Sen. Anning’s comments were ugly and divisive. They were dangerous and unacceptable from anyone, let alone a member of this place,” Government Senate Leader Mathias Cormann told the Senate.

Anning dismissed the censure motion as an attack on free speech. “It is also an exercise in left-wing virtue signaling of the worst kind,” he told the Senate before the vote.

One Nation Sen. Peter Georgiou read a speech on behalf of party leader Pauline Hanson, who was absent.

“If One Nation endorses your action to censure Sen. Anning, your freedom of speech as elected members of this chamber will be removed,” the speech said.

A day after the Christchurch attacks, Anning faced more criticism for physically striking the teenager who cracked an egg on his head at a Melbourne public appearance 17-year-old Will Connolly, who became known around the world as “Egg Boy.”

Anning on Wednesday criticised Prime Minister Scott Morrison for saying at the time that Anning should “be subject to the full force of the law” for his retaliation against Connolly. Police investigated the altercation but no charges have been announced.

“It might have only been an idiot with an egg this time, but there is a continuum that begins with this and ends with a fanatic with a gun or a bomb,” Anning said.

“But apparently, according to Prime Minister Morrison, that’s OK, as long as the victims are conservatives,” he added.

After New Zealand Prime Minister Jacinda Ardern previously called Anning’s comments on the shootings “a disgrace,” her deputy Winston Peters on Tuesday called Anning a “jingoistic moron.”

Australian white supremacist Brenton Tarrant has been charged with murder in the shootings and is due to appear in a New Zealand court on Friday.