A Queens inmate who had insisted that he was innocent of a 1993 murder was sentenced to 5 to 15 years for the lesser charge of second-degree manslaughter Monday as part of a plea deal with the Queens District Attorney’s Office.

Anthony Nwobi, a Nigerian immigrant, was found guilty in 1993 of fatally shooting his friend, Justin Eze, during a fight over a botched business deal at the home of a man named Gregory Reece. Nwobi has served 21 years of a 25-year-to-life sentence.

In November, Nwobi filed a motion to vacate his conviction, saying that Queens prosecutors withheld exculpatory evidence showing Reece was the real shooter.

While re-investigating the case, the district attorney’s office in May found a 2009 letter from Nwobi to a Queens detective in which Nwobi wrote he “accidentally” shot Eze. The office offered to grant Nwobi’s motion to vacate his murder conviction if he pleaded guilty to second-degree manslaughter.

At a hearing July 1 before Acting Queens County Supreme Court Justice Joel Blumenfeld (See Profile), Nwobi admitted he brought a gun to Reece’s home and pulled the trigger.

In addition to the manslaughter sentence, Blumenfeld on Monday gave Nwobi eight-and-a-third to 25 years for first-degree burglary and five to 15 years for criminal possession of a weapon. State prison authorities will now determine how much time Nwobi will be credited with having served.

Nwobi, who holds a green card, may be deported when he gets out of prison. U.S. Immigration and Customs Enforcement issued an order for his removal in 1998, said Queens Executive Assistant District Attorney Robert Masters.

Nwobi’s attorney, Rita Dave, said she will focus on keeping her client in the United States.