ELWOOD, Ind. (AP) — An Indiana police officer was fatally shot during a traffic stop early Sunday. Noah Shahnavaz worked for the Elwood police department, 50 miles northeast of Indianapolis.

State police say a driver got out of his vehicle and shot the 24-year-old officer.

The suspect was captured roughly 30 minutes later.

Madison County Sheriff Scott Mellinger says he’s gone from “being prayerful to being angry.” The prosecutor’s office says the suspect has a criminal record, which includes a conviction in 2006 for firing a gun at Indianapolis officers.

Shahnavaz had been an Elwood police officer for 11 months after serving five years in the U.S. Army.