A federal judge on Saturday temporarily blocked the deportation of a New York pizza delivery man who was arrested by ICE during his delivery to a military base.

Pablo Villavicencio will remain in ICE custody in New Jersey until his case goes to court.

His arrest, which came after Fort Hamilton guards requested identification before letting him onto the base to make his delivery, caused an uproar in New York City.

A federal judge on Saturday temporarily blocked the deportation of a New York pizza shop worker to his native Ecuador after he was arrested while making a delivery to a Brooklyn Army base.

Attorneys for The Legal Aid Society obtained the temporary stay for Pablo Villavicencio after a hearing in Manhattan federal court.

The 35-year-old married father of two young girls was arrested on June 1 while making a delivery to the garrison in Fort Hamilton. A routine background check revealed there was a warrant for his arrest for immigration law violations.

Federal Judge Alison Nathan granted the stay until July 20. Villavicencio will remain in Immigration and Customs Enforcement custody in New Jersey until his case goes to court.

New York Gov. Andrew Cuomo had asked federal homeland security officials to look into the case, saying recent detentions raise significant legal questions.

In a letter to the ICE office in New York, the Democrat said Villavicencio's "expedited removal serves no legitimate public safety purpose and the circumstances leading to his arrest and detention raise serious legal and policy concerns."

Villavicencio's wife, Sandra Chica, is an American citizen and their daughters, ages 2 and 3, were born in the US

'Hasty, cruel, and reckless'

In this undated family photo provided by Sandra Chica, Pablo Villavicencio poses with his two daughters, Luciana, left, and Antonia. Villavicencio family via Associated Press When Villavicencio arrived at Fort Hamilton, guards requested identification and he produced a city identification card.

When one guard said the card wasn't valid and that Villavicencio needed a driver's license, he replied that he didn't have one.

The guards then conducted a background check, which showed that Villavicencio had been ordered to leave the United States in 2010, but stayed.

The guards detained him, called ICE officers, and he was arrested. Villavicencio's wife told The New York Times that the personnel at the base still accepted the food he had delivered.

Redmond Haskins, a spokesman for The Legal Aid Society, a not-for-profit organization that provides free services to clients who cannot afford them, said Villavicencio has no criminal record.

Haskins said attorneys worked through the night preparing the emergency stay request that was argued in court on Saturday afternoon.

"Although we are disappointed that Pablo will remained detained, today's stay is a victory for him and his family, and also for due process and the fair administration of justice," said Gregory Copeland, the supervising attorney of Legal Aid's Immigration Law Unit. "This decision is also a reminder that the judiciary can still serve as a powerful check when other branches of government make hasty, cruel and reckless decisions."

The attorneys said they will work with Villavicencio to help him secure valid immigration status.