A 17-year-old illegal immigrant — behind bars on a murder charge — was released from a local North Carolina jail that just pulled out of an immigration screening program with Immigration Customs and Enforcement (ICE).

Sergio Coello-Perez, a Mexican national, was released from the Mecklenburg County Jail on Thursday after seven months in custody.

He was released with a written promise to appear in court and to wear a 24-hour electronic monitoring bracelet, WBTV reported Friday.

On Friday, the teen was booked into the jail again.

That happened after prosecutors obtained a court order for his arrest “to correct a clerical error” dealing with his bond status, according to the television station.

Related: California Sheriff on the State’s Sanctuary Policy: ‘Dangerous and Irresponsible’

Coello-Perez was sprung for 31 hours, the station reported.

He was 16 in May when prosecutors said that he and a friend tried to steal a car in Charlotte and then shot and killed the owner, Nicholas Boger, who tried to stop them.

A judge jailed Coello-Perez without bail after his arrest for that crime.

WBTV reported that Immigration and Customs Enforcement had a hold on Coello-Perez at the jail.

He announced that he was ending the screening program that allowed deputies to perform immigration enforcement duties inside the jail with supervision from ICE. McFadden said ICE officials would need court-issued warrants or detainers to access the jail while he is sheriff.

Who do you think would win the Presidency?

By completing the poll, you agree to receive emails from LifeZette, occasional offers from our partners and that you've read and agree to our privacy policy and legal statement.

The station quoted a spokesperson for the Mecklenburg County Sheriff’s Office as saying that the “ICE hold was lifted” — but that was not why Coello-Perez was released.

Three weeks ago Garry McFadden was sworn in as Mecklenburg County sheriff.

He announced that he was ending the screening program that allowed deputies to perform immigration enforcement duties inside the jail with supervision from ICE.

McFadden said ICE officials would need court-issued warrants or detainers to access the jail while he is sheriff.

The program had sent thousands of people into deportation proceedings since 2006.

Related: Illegal Fugitive Kills Legal Immigrant — Sens. Pelosi, Harris Silent About It

Ending that program was a major part of McFadden’s election campaign.

And check out this video:

The Associated Press contributed to this Fox News report, which is used by permission.

Read more at Fox News:
Hunting and Fishing: The Craziest Kills and Catches of 2018
Michigan Women Accused of Stealing at Target During ‘Shop with a Cop’ Event
Behind the Mattis Resignation: More Resignations Expected After ‘Protest Exit’