A high school in Orange County was temporarily placed on lockdown Thursday morning after a man wandered onto the campus and told security he had a weapon.

It happened around 12 p.m. on the campus of San Juan Hills High School in San Juan Capistrano, according to the Orange County Sheriff’s Department.

Officials said the man walked onto the campus and was immediately stopped by campus security. The man allegedly told the security guards that he was armed with a weapon.

The school was placed on lockdown and the man was searched, Sheriff’s Department officials said.

As it turns out, the weapon was actually a pocket knife that the man had on his person.

The lockdown was eventually lifted and the unidentified man was taken into custody, the Sheriff’s Department said. It’s unclear if he was arrested or simply escorted off of property.