Updated

A Phoenix police officer was critically injured in a shooting Thursday night while pulling over a suspect, authorities said.

Both the officer and suspect were rushed to a hospital in critical condition, FOX10 Phoenix reported. Police did not specify the extent of their injuries.

The officer was shot around 8 p.m. in the area of Catcus and Cave Creek, Phoenix police Sgt. Mercedes Fortune said during a briefing.

The suspect fired two shots at the officer, who was getting out of his marked car, police said. The officer returned fire and wounded the suspect. Police could not say whether the officer had been shot twice.

Police Chief Jerri Willis said the officer was “ambushed.”

The officer, who has not been identified, has been with the department for about one year, Willis said. She couldn’t give his age, but called him one of their “younger” officers.

It wasn’t immediately clear why the suspect was being pulled over.

"You come to work, and you hope for the best, you know, understanding that not everybody, obviously, wants to cause us harm, but you just never know,” said Fortune.

Willis said this marked Phoenix’s 34th officer involved shooting this year.

This is a developing story. Check back for updates.