A former ICE special agent told Fox News that he hopes the case of the Massachusetts judge accused of helping an illegal immigrant flee federal authorities will “send a message to other activist judges that immigration laws aren’t optional.”

Jim Hayes made the comments Friday on ‘Fox & Friends’ a day after Newton District Court Judge Shelley M. Richmond Joseph and court officer Wesley MacGregor were indicted by a federal grand jury for obstruction of justice and three other counts. The pair allegedly helped Jose Medina-Perez get out of the Massachusetts courthouse in 2018 through a back door in order to elude the ICE agent who sought him.

“I think that the judge certainly faces the criminal charges that are pending. I think certainly that bar card is up for grabs at this point, depending on the outcome of that case,” Hayes told ‘Fox & Friends’.

“I think that, hopefully, these charges will send a message to other activist judges that immigration laws aren’t optional,” he added.

District Court Judge Shelley M. Richmond Joseph departs federal court on Thursday in Boston after facing obstruction of justice charges for allegedly helping a man in the country illegally evade immigration officials as he left her Newton, Mass., courthouse after a hearing in 2018. (AP)

MASSACHUSETTS JUDGE WHO ALLEGEDLY HELPED ILLEGAL IMMIGRANT ESCAPE ICE IS INDICTED

Medina-Perez, a twice-deported illegal immigrant with a fugitive warrant for drunken driving in Pennsylvania, had been in Joseph's courtroom in order to be arraigned on drug charges, the Boston Globe previously reported.

CLICK HERE TO GET THE FOX NEWS APP

Joseph, who has been suspended without pay, and MacGregor appeared in court Thursday and pleaded not guilty to all counts. No date has been set for their next court appearance.

“People who serve in the criminal justice system have to have honesty and integrity in order for the system to work and for our system and our justice system to continue,” Hayes said.

Fox News’ Katherine Lam and Nicole Darrah contributed to this report.