A wrongfully convicted Black man has been freed after serving 18 years in prison, despite a botched identification. On Thursday (March 9), a Brooklyn judge vacated the indictment and overturned the 25 years-to-life sentence given to Sheldon Thomas for the 2004 murder of Anderson Bercy, 14, on Christmas Eve. According to CNN, detectives misled a witness into identifying Thomas by giving them a photo of man with the same name. When a judge learned about the misidentification, he stated that there was still probable cause for Thomas’ arrest and that the picture had enough resemblance, according to a statement from Brooklyn District Attorney Eric Gonzales.

“[The] [case] was compromised from the very start by grave errors and lack of probable cause to arrest Mr. Thomas,” Gonzales noted. “He was further deprived of his due process rights when the prosecution proceeded even after the erroneous identification came to light, making his conviction fundamentally unfair.”

Thomas was one of three alleged gang members arrested in connection to the 14-year-old deceased victim and for wounding another person. When conducting their investigation, police reportedly asked to use an image of Thomas, who was 17 at the time, from a prior gun arrest to show the eyewitness as part of their lineup, the DA’s office mentioned. However, before receiving that photo, authorities printed a picture of another man, whose name was also Sheldon Thomas, from their database. Per Gonzales, when the witness saw the lineup, she picked out the printed image, unaware it was not the victim who spent 18 years behind bars.

The wrongfully convicted Thomas was arrested along with two others identified by the witness. But charges against the other men were dismissed. It wasn’t until a 2006 pretrial hearing that Gonzales said a detective on the case revealed that he used the wrong picture for the lineup. But because of the anonymous tips and photo resemblance, the newly freed Thomas was found guilty of second-degree murder, five counts of attempted murder, and weapons charges. He was given a life sentence.

After the judge announced the overturning of his conviction, Thomas said, “There [were] so many times when I was in my cell [that] I would think of this moment. Right now, I’m just speechless.” According to a DA’s office spokesperson, their conviction reversal unit, which has had 34 convictions vacated since 2014, currently has 50 open investigations. “We must strive to ensure fairness and integrity in every case and have the courage to correct mistakes of the past,” Gonzales stated.