The NYPD reportedly alerts federal immigration officials to illegal immigrants’ appearances in criminal court despite Mayor Bill de Blasio’s vow to remain a sanctuary city.

The NYPD’s process of verifying warrants against a defendant includes contacting relevant law enforcement agencies, including ICE, which alerts agents to an illegal immigrant’s upcoming court date, the New York Daily News reported Sunday.

New York City has vowed to only alert immigration officials if an illegal immigrant is accused of a violent crime.

An NYPD administrative aide noted that ICE was contacted about the arrest of David Gonzalez, 51, on March 2 and Milton Chimborazo, 35, on March 15, the Daily News reported. Gonzalez, who had been previously deported, was facing misdemeanor charges for allegedly rubbing up against a woman on a subway train, while Gimborazo had a standing deportation order and was facing a burglary charge.

The city had failed to comply with ICE “detainer” orders, but immigration officials showed up to court anyway. ICE took Gonzalez into custody after he was released by a judge, but agents did not arrest Gimborazo.

Stephen Davis, spokesman for the NYPD, told the Daily News that the cases were handed properly.

“Nothing was compromised in terms of the policies of the department. These guys didn’t suffer any consequence,” he said.

Austin Finan, a spokesman for de Blasio, told the newspaper that ICE and the NYPD regularly communicate, but it did not mean that police always honor detainers.

De Blasio touted the city’s sanctuary city policy in January, calling it a “good model for the nation.”

"Any serious or violent crime, we are going to work with [immigration authorities]," De Blasio said, adding that otherwise, an immigrant who "went through a stop sign could be deported for that."

Click for more from the New York Daily News.