A teenager has pleaded guilty to murder in Ramsey County District Court for killing a man who tried to stop him from assaulting his girlfriend.

Theotis Thomas pleaded guilty Tuesday to second-degree murder in the fatal shooting of 21-year-old Mark Franklin Jr. The 19-year-old defendant also pleaded guilty to making threats of violence toward a 17-year-old who witnessed the shooting.

The St. Paul Pioneer Press reports Franklin was trying protected his cousin when Thomas wrapped his hands around her neck last March at a Frogtown home. Thomas fired a gun into a bedroom wall. Franklin tried to wrestle the gun away from him. Thomas’ girlfriend also tried to intervene, but Thomas wound up shooting Franklin in the face.

A plea deal calls for four additional criminal counts to be dropped when Thomas is sentenced in August.