Fredericton police used a stun gun on a man who allegedly assaulted a fellow officer overnight Sunday, a spokesperson says. 

"He was kicking and very violent towards the police," said Sgt. David McLean of the Fredericton Police Force. 

"At that point, police had to deploy the connected energy device."

The man who was Tasered was initially under arrest because of an outstanding warrant, breaching a judge's undertaking. Police did not identify what the undertaking was.

McLean said the officer did not suffer any injuries and did not go to hospital.

Fredericton police made two other arrests overnight for outstanding warrants.

Two other people were also arrested but were taken to hospital  because the call was mental-health related.

McLean would not comment on whether any of the arrests were connected.

The five arrested people are expected to appear in court.