The crazy series of events that brought down the suspect in the New York and New Jersey bombings

Before you go, we thought you'd like these...

The arrest of a New Jersey terrorism suspect was the culmination of classic police work, bystander intervention, and incompetence on behalf of the suspect himself.

Police in Linden, New Jersey, apprehended 28-year-old Ahmad Khan Rahami after a shootout late Monday morning.

SEE ALSO: Classmate of bombing suspect describes a quiet, 'funny' teen

Rahami is suspected of being involved in three incidents throughout the weekend — a bombing along the route of a New Jersey charity race Saturday morning, a bombing Saturday night in New York City that injured 29 people, and the planting of additional devices in Elizabeth, New Jersey, on Sunday night.

It seems like whatever plot Rahami was trying to carry out didn't go as planned.

See photos of Rahami and his capture after a gun battle with police:

24 PHOTOS
Authorities investigate Residence in Elizabeth NJ for Chelsea Bombing
See Gallery
Authorities investigate Residence in Elizabeth NJ for Chelsea Bombing
Ahmad Khan Rahami, who is wanted for questioning in connection with an explosion in New York City, is seen in this image released by the New Jersey State Police on September 19, 2016. Courtesy New Jersey State Police/Handout via REUTERS ATTENTION EDITORS - THIS IMAGE WAS PROVIDED BY A THIRD PARTY. FOR EDITORIAL USE ONLY
Ahmad Khan Rahami, who is wanted for questioning in connection with an explosion in New York City, is seen in this image taken from video, released by the New Jersey State Police on September 19, 2016. Courtesy New Jersey State Police/Handout via REUTERS ATTENTION EDITORS - THIS IMAGE WAS PROVIDED BY A THIRD PARTY. FOR EDITORIAL USE ONLY
Law enforcement officers mark evidence near the site where Ahmad Khan Rahami, sought in connection with a bombing in New York, was taken into custody in Linden, New Jersey, U.S., September 19, 2016. REUTERS/Eduardo Munoz
Law enforcement officers mark evidence near the site where Ahmad Khan Rahami, sought in connection with a bombing in New York, was taken into custody in Linden, New Jersey, U.S., September 19, 2016. REUTERS/Eduardo Munoz TPX IMAGES OF THE DAY
Law enforcement officers secure the area where they allegedly arrested terror suspect Ahmad Khan Rahami following a shootout in Linden, New Jersey, on September 19, 2016. The FBI led a major manhunt Monday for an 'armed and dangerous' Afghan-born American wanted in connection with weekend bombings in New York and New Jersey as a third nest of bombs was discovered in his hometown. Federal investigators released a mugshot of 28-year-old Ahmad Khan Rahami, who has brown hair, brown eyes and a brown beard, saying he was last known to live in Elizabeth, a town adjacent to Newark International Airport. / AFP / Jewel SAMAD (Photo credit should read JEWEL SAMAD/AFP/Getty Images)
Ahmad Khan Rahami alive but injured, loaded into ambulance in Linden https://t.co/aMCNYxwFnH https://t.co/JJlFhPLYSu
ELIZABETH, NJ - SEPTEMBER 19: A local police officer stands guard at an intersection as members of the Federal Bureau of Investigation (FBI) and other law enforcement officials investigate a residence in connection to Saturday night's bombing in Manhattan on September 19, 2016 in Elizabeth, New Jersey. This morning law enforcement released a photograph of 28-year-old Ahmad Khan Rahami, who they are seeking in connection to the attack in Chelsea. (Photo by Drew Angerer/Getty Images)
Onlookers watch while Federal Bureau of Investigation (FBI) personnel search an address during an investigation into Ahmad Khan Rahami, who was wanted for questioning in an explosion in New York, which authorities believe is linked to the explosive devices found in New Jersey, in Elizabeth, U.S., September 19, 2016. REUTERS/Eduardo Munoz
ELIZABETH, NJ - SEPTEMBER 19: Members of the Federal Bureau of Investigation (FBI) and other law enforcement officials investigate a residence in connection to Saturday night's bombing in Manhattan on September 19, 2016 in Elizabeth, New Jersey. This morning law enforcement released a photograph of 28-year-old Ahmad Khan Rahami, who they are seeking in connection to the attack in Chelsea. (Photo by Drew Angerer/Getty Images)
ELIZABETH, NJ - SEPTEMBER 19: Members of the Federal Bureau of Investigation (FBI) and other law enforcement officials investigate a residence in connection to Saturday night's bombing in Manhattan on September 19, 2016 in Elizabeth, New Jersey. This morning law enforcement released a photograph of 28-year-old Ahmad Khan Rahami, who they are seeking in connection to the attack in Chelsea. (Photo by Drew Angerer/Getty Images)
ELIZABETH, NJ - SEPTEMBER 19: Members of the Federal Bureau of Investigation (FBI) and other law enforcement officials work near a residence they are investigating in connection to Saturday night's bombing in Manhattan on September 19, 2016 in Elizabeth, New Jersey. This morning law enforcement released a photograph of 28-year-old Ahmad Khan Rahami, who they are seeking in connection to the attack in Chelsea. (Photo by Drew Angerer/Getty Images)
ELIZABETH, NJ - SEPTEMBER 19: Members of the Federal Bureau of Investigation (FBI) and other law enforcement officials investigate a residence in connection to Saturday night's bombing in Manhattan on September 19, 2016 in Elizabeth, New Jersey. This morning law enforcement released a photograph of 28-year-old Ahmad Khan Rahami, who they are seeking in connection to the attack in Chelsea. (Photo by Drew Angerer/Getty Images)
ELIZABETH, NJ - SEPTEMBER 19: A local police officer stands guard at an intersection as members of the Federal Bureau of Investigation (FBI) and other law enforcement officials investigate a residence in connection to Saturday night's bombing in Manhattan on September 19, 2016 in Elizabeth, New Jersey. This morning law enforcement released a photograph of 28-year-old Ahmad Khan Rahami, who they are seeking in connection to the attack in Chelsea. (Photo by Drew Angerer/Getty Images)
ELIZABETH, NJ - SEPTEMBER 19: Members of the Federal Bureau of Investigation (FBI) and other law enforcement officials investigate a residence in connection to Saturday night's bombing in Manhattan on September 19, 2016 in Elizabeth, New Jersey. This morning law enforcement released a photograph of 28-year-old Ahmad Khan Rahami, who they are seeking in connection to the attack in Chelsea. (Photo by Drew Angerer/Getty Images)
Elizabeth NJ. Mayor J. Christian Bollwage answers a question as he stands not far from where police and officials gathered at a building early Monday, Sept. 19, 2016, in Elizabeth, N.J. The Elizabeth apartment is tied to a man wanted for questioning in the New York City bombing. Ahmad Khan Rahami has lived at that address in Elizabeth. He is a naturalized citizen from Afghanistan, the FBI said. (AP Photo/Mel Evans)
***WANTED FOR QUESTIONING**** RETWEET! https://t.co/B3IgarqY2D https://t.co/QUjCFdtVc2
ELIZABETH, NJ - SEPTEMBER 19: Law enforcement officials tow a car near the site of an investigation of a residence in connection to Saturday night's bombing in Manhattan, September 19, 2016 in Elizabeth, New Jersey. On Monday morning, law enforcement released a photograph of 28-year-old Ahmad Khan Rahami, who they are seeking in connection to the attack. (Photo by Drew Angerer/Getty Images)
FBI agents walk around the roof outside an apartment during an investigation at a building Monday, Sept. 19, 2016, in Elizabeth, N.J. FBI agents are searching the apartment in New Jersey that is tied to Ahmad Khan Rahami wanted for questioning in the New York City bombing. (AP Photo/Mel Evans)
An FBI agent carries a box of material from an apartment to a car during an investigation at a building in Elizabeth, N.J. early Monday, Sept. 19, 2016. The Elizabeth apartment is tied to a man wanted for questioning in the New York City bombing. Ahmad Khan Rahami has lived at that address in Elizabeth. He is a naturalized citizen from Afghanistan, the FBI said. (AP Photo/Mel Evans)
Federal Bureau of Investigation (FBI) personnel search an address during an investigation into Ahmad Khan Rahami, who was wanted for questioning in an explosion in New York, which authorities believe is linked to the explosive devices found in New Jersey, in Elizabeth, U.S., September 19, 2016. REUTERS/Eduardo Munoz
ELIZABETH, NJ - SEPTEMBER 19: A man exits from the fried chicken restaurant and walks to a car, near the site of where members of the Federal Bureau of Investigation (FBI) and other law enforcement officials are investigating a residence in connection to Saturday night's bombing in Manhattan, September 19, 2016 in Elizabeth, New Jersey. On Monday morning, law enforcement released a photograph of 28-year-old Ahmad Khan Rahami, who they are seeking in connection to the attack. (Photo by Drew Angerer/Getty Images)
Ahmad Khan Rahami is taken into custody after a shootout with police Monday, Sept. 19, 2016, in Linden, N.J. Rahami was wanted for questioning in the bombings that rocked the Chelsea neighborhood of New York and the New Jersey shore town of Seaside Park. (Moshe Weiss via AP)
Policemen place in an ambulance a man they identified as Ahmad Khan Rahami, who is wanted for questioning in connection with an explosion in New York City, in Linden, New Jersey, in this still image taken from video September 19, 2016. REUTERS/Anthony Genaro
A policeman takes a photo of a man they identified as Ahmad Khan Rahami, who is wanted for questioning in connection with an explosion in New York City, as he is placed into an ambulance in Linden, New Jersey, in this still image taken from video September 19, 2016. REUTERS/Anthony Genaro TPX IMAGES OF THE DAY
of
SEE ALL
BACK TO SLIDE
SHOW CAPTION +
HIDE CAPTION

First, on Saturday morning, the bomb that went off at the race in New Jersey detonated while no bystanders were around, so no one was injured and no structures were damaged. And the device didn't work to its full potential — it consisted of three pipe bombs tied together, only one of which detonated.

The timing was also off. The start of the race had coincidentally been delayed, so the bomb exploded 30 minutes after the race would have started, according to Reuters.

SEE ALSO: New York resident recalls discovering second bomb: 'I thought it was a kid's science project'

Then, later that night in New York City, a bomb went off near the intersection of West 23rd Street and 6th Avenue in Manhattan. Because the bomb had been placed in a dumpster, which had thick metal sides, the explosion didn't kill anyone, and nearly all of the 29 injured escaped without any serious damage. Officials said the device had been packed with BBs and ball bearings.

Another device was then found on nearby West 27th Street.

The suspect failed on multiple levels here — he was caught on surveillance video planting the bombs, the second bomb didn't detonate, and the cellphone taped to the bomb provided clues to authorities that helped identify him. Police also found a fingerprint that helped identify Rahami.

Then, on Sunday, authorities said two homeless people found a backpack full of explosives abandoned outside a restaurant in Elizabeth, New Jersey, and reported it. The bag, which contained five pipe bombs, did not explode.

"They probably saved hundreds of people," Mayor Christian Bollwage said.

Shortly after that, police publicly identified Rahami as a suspect. Authorities blasted out emergency cellphone notifications with the suspect's name and identifying information, and the FBI released a photo of Rahami, which was broadcast widely on the news.

This is what eventually led to Rahami's arrest.

Harinder Bains, who owns Merdie's Tavern in Linden, New Jersey, had been watching the news and saw Rahami's photo, according to CNN. Later on Monday, he went over to his bar and found a man sleeping in the doorway who looked like Rahami, so he called police.

An officer arrived an identified him, and after an exchange of gunfire, Rahami was taken into custody.

NOW WATCH: A hair surgeon explains what's going on with Donald Trump's hair

See Also:

Read Full Story

People are Reading