MIDDLETOWN, Pa. – A Pennsylvania high schooler got what he wanted after allegedly posting a threatening message to Twitter about Middletown schools.

Lower Swatara Township police report a 15-year-old Middletown Area High School student posted the message to Twitter shortly after midnight: “School shooting tomorrow – who’s ready Middletown?”

MORE NEWS: Know These Before Moving From Cyprus To The UK

Police tracked down the student, who was not identified in news reports, in about two hours. Police went to the student’s home early this morning, where he allegedly confessed to posting the threat, ABC 27 and Fox 43 report.

The teen told police he wasn’t serious, but rather simply wanted the day off from school, according to PennLive.com.

And it seems he got exactly what he wanted.

“Police said the student was not permitted to attend school today,” the news site reports.

The incident certainly isn’t the first time officials have investigated threats against schools over social media.

Fresno Police officials in California in late August advised administrators at San Joaquin Memorial High School to cancel classes after a student quoted rapper Eminem on Instagram, threatening to “shoot up the school with an AK-47,” according to ABC 30.

MORE NEWS: How to prepare for face-to-face classes

Officials in North Berwick, Maine also investigated “a credible threat” about a bomb at Noble High School that was posted to Twitter in January, WMUR reports.

School officials evacuated the school and moved students to a middle school for the day before canceling school around mid-day. School officials contacted parents about the episode, but did not release details about the threat to the media.

And last November, two Manhattan Beach, California schools shut down after a suspected threat was posted to Yik Yak, a social media app in which users can comment anonymously.

“If you go to Costa you should watch out very closely at school today,” the post read, according to ABC 7.

Officials closed Mira Costa High School in response, as well as nearby The Montessori School.

A second message sent later the same afternoon read “nice try costa, today was just a drill.”

Yik Yak developers said the app allows users to send an anonymous message to others within a 1.5 mile radius, but uses GPS technology to ensure messages are not sent from middle or high school campuses, which means the Manhattan Beach threat came from outside of the school, officials said.