JACKSONVILLE, N.C. (AP) — A man found guilty of the lesser offense of voluntary manslaughter in a shooting during a robbery that started as a drug deal has been sentenced to at least five years in prison.

Corey Thomas was on trial for murder this week, but media outlets report a jury found the 28-year-old Jacksonville man guilty of voluntary manslaughter.

A judge Friday sentenced Thomas to between five years and five months to seven years and six months in prison.

Thomas says he didn’t intend to kill 27-year-old Robert Ward in July 2014. He says Ward and another man robbed and attacked him before he shot Ward in the head.

Prosecutors said Thomas shot Ward several times when one shot was enough to protect himself without killing Ward.