Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

Two New York Police Department (NYPD) detectives were acquitted Thursday on charges of beating a postal worker who unknowingly gave directions to the man who ambushed and killed Officers Wenjian Liu and Rafael Ramos in 2014.

One Police Plaza, the New York Police Department headquarters, is seen in New York. Mary Altaffer / AP

Queens Supreme Court Justice Michael Aloise found Detectives Angelo J. Pampena, 32, and Robert A. Carbone, 30, not guilty of all charges in a five-count indictment that included second- and third-degree assault. The men chose to be tried by judge rather than jury.

The pair was accused of kicking and punching Karim Baker, 27, and then dragging him from his parked car onto the sidewalk in October 2015, Queens District Attorney Richard A. Brown said in a statement in April following their indictment.

RELATED: Cops Arraigned in Beating of Postal Worker Who Unknowingly Gave Killer Directions

Baker suffered bruises to his face, tears to ligaments in his knee, and injuries to his spine, according to his lawyer.

“The two defendants were acquitted and the case is now sealed and we cannot comment,” a spokesperson for the Queens DA’s office told NBC News on Friday.

Michael Palladino, president of the Detectives’ Endowment Association, welcomed the verdict.

The Morning Rundown Get a head start on the morning's top stories. This site is protected by recaptcha

“From the beginning, this appeared to be an overzealous prosecution on the part of the Queens district attorney's office,” Palladino told NBC News.

Messages left with both detectives’ attorneys Friday morning were not immediately returned.

Ismaaiyl Brinsley, who fatally shot Liu and Ramos on Dec. 20, 2014, approached Baker earlier that day for directions to a housing project. At the time, Baker was a FedEx employee and was on a Brooklyn street delivering packages. Brinsley committed suicide shortly after shooting the officers.

Baker’s attorney, Eric Subin, has said his client did not know Brinsley, who had made threats against police on social media before killing Liu and Ramos.

Subin said Baker was questioned about his encounter after being seen on surveillance video providing the directions. In the months that followed, Baker alleges police harassed him repeatedly with 20 traffic stops over a 10-month period — a claim the NYPD has denied.

RELATED: Two Years After Deaths, Service Keeps Memory of Slain NYPD Cops Alive

According to the Queens district attorney, Pampena had filed a criminal court complaint stating Baker was parked directly in front a fire hydrant the evening the two detectives approached him, but video footage revealed the car was more than 15 feet away.

A criminal case against Baker was later dropped and the file sealed, prosecutors said.

Baker, who took the stand in the criminal trial against the two detectives, is suing the city and NYPD for $100 million. He has not been able to return to work because of his injuries, according to Subin.

“He’s terrified, he’s absolutely terrified,” Subin told NBC News when asked how Baker was doing after the verdict.

“He was worried beforehand because he didn’t want to take the stand and be in the same room as these guys,” he added.

Police officers line the streets before the funeral of Officer Wenjian Liu in the Brooklyn borough of New York, Sunday, Jan. 4, 2015. Liu and his partner, officer Rafael Ramos, were killed Dec. 20 as they sat in their patrol car on a Brooklyn street. The shooter, Ismaaiyl Brinsley, later killed himself. Seth Wenig / AP

Pampena and Carbone were originally suspended without pay for 30 days and then placed on modified assignment, stripped of their gun and badge, Palladino said.

An NYPD spokesperson told NBC News in an email that the detectives remained on modified duty and that internal charges were still pending.

Palladino said the union will defend Pampena and Carbone if the department charges them.

Follow NBC Asian America on Facebook, Twitter, Instagram and Tumblr.