Washington (AFP) – The Minnesota police officer whose fatal shooting of a black driver this week helped prompt nationwide protests against racial prejudice reacted to the man’s gun, not his race, his lawyer said.

Jeronimo Yanez, a police officer in St. Anthony, a Minneapolis suburb, “was reacting to the presence of a gun” when he shot Philando Castile, Minneapolis attorney Thomas Kelly told The New York Times.

Castile, 32, was shot Wednesday after he was pulled over in Falcon Heights, near Minneapolis, for a broken tail light.

Amplifying the horror was the video live-streamed in the shooting’s aftermath by the slain man’s girlfriend, Diamond Reynolds, as she sat in the passenger seat. Her four-year-old daughter was sitting in the back seat.

Castile was shot after informing the officer that he had a gun and a permit to carry, and then reaching for his wallet, according to Reynolds.

He was the second black man in two days fatally shot by US police. They are the latest in a string of similar cases that have fueled outrage across the United States, from city streets to the White House.

Although Kelly provided the fullest account so far of Yanez’s version of the shooting on Wednesday, many details remain unclear.

Yanez, who is Latino, is on leave while the state authorities are investigating the shooting.

“The shooting had nothing to do with race and everything to do with the presence of that gun,” Kelly told the Times.

Castile “was not following the directions of the police officer,” he added, declining to provide more details, the paper said.

There was “more than the reason for the equipment violation” to stop Castile’s car, Kelly said, without specifying other reasons, the Times said.

Governor Mark Dayton, who met with protesters and black leaders, has expressed sympathy for the Castile family and concerns about the role of race in the shooting, infuriating some in law enforcement.

“Would this have happened if those passengers — the driver and the passengers — were white?” he said Thursday. “I don’t think it would’ve.”

The fatal shooting of Castile and another black man, Alton Sterling, in Louisiana the previous day, prompted protests against police brutality toward African Americans under the banner of the Black Lives Matter movement.

During a protest in Dallas on Thursday, a lone gunman bent on revenge opened fire on police, killing five officers and wounding seven others, deepening divisions in a shocked country. The authorities identified the Dallas shooter, who was black, as an Army veteran who was later killed by police.

Fresh protests were planned on Saturday.