NEW YORK -- Authorities say a New York City man has been arrested on charges he built an explosive to attack a police officer and instead killed an innocent bystander. Federal prosecutors charged Victor Kingsley on Wednesday with using a weapon of mass destruction and illegally transporting an explosive.

A criminal complaint says Kingsley wanted to use homemade bombs to retaliate against police officers who arrested him in a case that was later dropped.

It says last year, Kingsley had one device planted on the porch of a Queens home where he mistakenly believed one of the officers lived. The building's landlord, George Wray, unknowingly opened the package, which exploded. Cellphone video taken immediately after the blast that showed Wray doubled over in pain.

"George Wray was not the intended target of the IED," NYPD Chief of Detectives Robert Boyce said in a Wednesday press conference. "We believe the IED was retaliatory for an arrest of Kingsley in January of 2014."

Get Breaking News Delivered to Your Inbox

First responders rushed him to the hospital with second-degree burns covering 80 percent of his body, but he didn't survive his injuries, reported CBS New York.

George Wray of Queens, New York, lies on a stretcher as he is wheeled to a nearby ambulance, after suffering severe burns from a package explosion on July 25, 2017. He later died. CBS New York

Wray owned the home, but did not live there.

Police said Thursday that the name of the officer who was the intended target was on the package and that intense data mining over the past several months led them to make an arrest. More materials that were possible pre-cursors to explosive devices were found in Kingsley's Brooklyn home when he was arrested, police said.

The 37-year-old Kingsley was awaiting an initial court appearance. The name of his attorney wasn't immediately available.