CAPE ELIZABETH — Two town school buildings had to be evacuated Thursday morning after teachers discovered “a threatening message” in a student bathroom.

Cape Elizabeth Police responded and recommended that the Pond Cove Elementary School and the Cape Elizabeth Middle School – the buildings are connected – be evacuated as a precautionary measure.

An e-mail alert sent to parents about the incident from Pond Cove principal Kelly Hasson and interim middle school principal Doug Perley said that public safety officials checked the buildings and “determined that there was no credible threat to the safety of the school community.”

The incident took place late Thursday morning. Students and staff were allowed to return to the buildings about 20 minutes after the students had been evacuated.

School officials described the evacuation as “calm, orderly, and brief,” but they gave no indication as to why they considered the message found in the bathroom to be threatening.

All of the town’s schools, including the high school, rehearsed an emergency lockdown drill on Wednesday, according to a notice sent home to parents and guardians.