A knife-wielding teenager was arrested just seconds after police say he carjacked an Uber driver.

According to the Dunwoody Police Department, at 9:20 a.m. Tuesday, a 16-year-old called for an Uber driver to pick him up. Once the ride arrived, the teen carjacked the driver and drove off, police said.

The driver of the Uber ran across the street and called 9-1-1. Luckily, an officer was nearby and responded to the incident quickly.

"You just react and trust what you know. You want to control it you rely on your instincts to make sure everything happens correctly," said Dunwoody Officer Yaakov Baum. "It was in the morning, so traffic was light and I figured I had a good chance of finding him

The teen only got about a mile away before the officer pulled him over.

"About 30 seconds after the call came out I find it driving the opposite way," Baum said. "Turned on my blue lights and sirens, turned around on it and the driver was very cooperative pulled right over."

The suspect was charged with High jacking a motor vehicle, aggravated assault and possession of a knife during the commission of a crime. He’s at the Dekalb County Youth Detention Center.

“It could have had a very different ending we're glad it ended he way it did,” said Dunwoody Police Department PIO Sgt. Aaron Belt.

The Uber driver told police she doesn’t plan on quitting her job.

Police say this is the first crime like this to ever happen within the city.

The victim was shaken, but physically unharmed, police said.