A 19-year-old has been arrested after allegedly texting with undercover agents that he planned an attack in the name of the Islamic State in Iraq and Syria (ISIS) in the New York City borough of Queens. A source familiar with the matter said the suspect, a Queens resident, was allegedly planning a knife attack, CBS News' Pat Milton reports.

The suspect is scheduled to appear Friday in federal court in Brooklyn, reports CBS New York.

The U.S. Attorney's Office said the 19-year-old, who allegedly texted with undercover agents about his plans, was arrested as part of a "national security investigation." Officials have not released the suspect's name or what his specific target might have been.

Get Breaking News Delivered to Your Inbox

The teen was reportedly under constant surveillance by law enforcement, and officials said in a statement that there is currently no public safety issue as a result of the arrest.

CBS New York reports the teen lives in a neighborhood in East Elmhurst, Queens.