An intruder broke into the building that houses Rep. Alexandra Ocasio-Cortez campaign office in Jackson Heights on Saturday and barricaded himself in a closet, police said.
The NYPD said the man, identified as Douala Hashi, 31, of Washington D.C., was emotionally disturbed and not related to the congresswoman.
Police initially said he was inside Ocasio-Cortez' office, but later said he was actually elsewhere in the building that houses her office.
"It appears to have been a coincidence that this happened in our building," said Corbin Trent, spokesman for Ocasio-Cortez. "We are glad that it was resolved peacefully."
The man held up a fire extinguisher, then locked himself in a janitor's closet, police said.
Officers were able to take him out and he was brought to an area hospital.
He was charged with menacing, criminal mischief and criminal trespass, according to police.
His attorney information wasn't immediately available.