Updated

The New York City Police Department has arrested the suspect wanted in the shooting of a rookie officer in the city’s Queens borough. 

Officials said that the shooting happened at around 3:30 p.m. Wednesday in Jamaica, Queens, after a New York City bus driver flagged two police officers down and told them that there were two men involved in a dispute involving a bus seat. The officer, who is 22 years old, is in stable condition and is still recovering Friday, according to NYPD Commissioner Keechant Sewell.

"The man who shot him immediately ran away and removed some of his outer clothing in an attempt to change his appearance -- but he could not evade our reach," Sewell told reporters Friday while announcing the arrest of Devin Spraggins, a 22-year-old whom police described a transient with connections to Poughkeepsie, New York, and Georgia.

Spraggins, who has no prior arrest record, is now facing charges including attempted murder of a police officer in the first degree after being taken into custody Thursday night in the Bronx.

LOUISIANA STATE POLICE USES SLAIN SERGEANT’S HANDCUFFS TO ARREST SUSPECT ACCUSED OF RAMMING COP CAR 

Devin Spraggins has a tattoo on his hand with the name "Jocelyn," police say. (NYPD)

NYPD Chief of Detectives James Essig said Friday that the shooting happened after Spraggins allegedly got into a dispute with a bus passenger Wednesday afternoon.

"He gets on the bus. He says to [a] male sitting there, 'Why are you staring at me? Get out of my seat.' There's some pushing and some altercations as the bus is proceeding," Essig said. "That's when the bus driver sees our officers on the street, flags them down and that's when the incident then takes place." 

Essig said detectives determined that Spraggins fled the scene in a Lyft vehicle following the shooting and through investigative work, he was tracked down to an apartment in the Bronx where he was arrested around 9 p.m. Thursday.

At that apartment, a 9mm handgun was found, and forensics testing is now ongoing to see if the weapon matches the 9mm shell casing recovered at the shooting scene.

Officials previously said when the two officers responded to the bus driver's call for help, Spraggins allegedly pushed them while exiting the bus and fled the scene, running north. 

GANG MEMBER WANTED FOR CALIFORNIA MURDER KILLED DURING POLICE STRUGGLE 

NYPD searching for suspect accused of shooting officer

Devin Spraggins was wanted by police in New York City for allegedly shooting at a police officer on Wednesday, April 5. (NYPD)

When one of the police officers caught up with the suspect, a brief struggle took place followed by the suspect allegedly firing a shot which struck near the officer's right hip, officials said. 

The other police officer on the scene fired his gun twice, but it is not known if Spraggins was struck. 

After the shooting, the suspect fled again into a parking garage and abandoned a black jacket, mask and sweatshirt he had been wearing before surveillance footage captured him walking away from the area in a white shirt and black pants, Essig said.

NYC police officer shot

Officials said that the shooting happened at around 3:30 p.m. in Jamaica, Queens, after an MTA driver flagged two police officers down and told them that there were two men involved in a dispute involving a bus seat. (Citizen App)

The injured officer was taken to Jamaica Hospital and is in stable condition.  

Sewell praised the wounded officer's partner, describing him as a fellow rookie who "did not hesitate to come to the aid of his fellow officer." 

CLICK HERE TO GET THE FOX NEWS APP 

"While he was running from a police officer and shooting at police officers there were children along that shopping corridor," Police Benevolent Association of the City of New York President Pat Lynch said Wednesday. "There were people that were just going about their lives... they had no regard for those people."  

The officer who was shot has only been a New York City police officer for three months, officials also said. 

Fox News' Jennifer Johnson contributed to this report.