A man accused of raping a woman in a stairwell in New York City on Saturday should have been in jail after not following through on a plea deal in a separate assault, according to a report.

Jamel McIver, 30, is charged with rape, burglary (sexually motivated) and criminal sex act, in an attack on a 21-year-old woman around 1 a.m. at a building near West 65th Street and West End Avenue. McIver’s own family reportedly turned him in to authorities.

At the time of the rape, law enforcement sources told the New York Post that McIver should have been in jail, but no one had told the judge.

McIver had taken a plea deal in August – related to a separate 2019 sex assault and burglary case – that required him to complete a two-year in-patient drug rehab program, the paper reported, citing police sources and court records. Failure to complete the program would result in five years in jail.

NEW YORK CITY SUSPECT FORCED YOUNG WOMAN INTO STAIRWELL, RAPED HER: POLICE

rape suspect on surveillance camera

Jamel McIver allegedly raped a 21-year-old woman in a stairwell Saturday night on the Upper West Side in Manhattan. (New York City Police)

However, at some point McIver left the program before finishing, the report said.

The city-funded Osborne Association, which placed McIver in rehab, told his defense attorney that he’d been removed for using drugs, but the lawyer didn’t immediately see the email, according to the report.

Surveillance footage of suspect

NYPD Crime Stoppers released images of the suspect, later identified as Jamel McIver, who allegedly raped a young woman after following her into a building. (New York Police Department)

Prosecutors in the Bronx said they didn’t know McIver was out of rehab and free until his arrest in the rape.

NEW YORK CITY FIREFIGHTERS BATTLE FIVE-ALARM FIRE STARTED BY E-BIKE BATTERY

When the judge asked McIver’s attorney why he hadn’t reported that his client had been kicked out of the rehab program, the attorney apologized and said a trial was taking up all his attention, the paper reported.

"Again, I did not give this the attention as needed because of my trial," he said. "I did not really look into it."

CLICK TO GET THE FOX NEWS APP

McIver is due to appear in court Friday for the rape charges.