A 16-year-old boy is accused of hacking into another student’s social media account Sunday and threatening to carry out a shooting at a high school in northwest Indiana.

The teen hacked into the male student’s Facebook account and posted a status that said he was going to shoot up Chesterton High School at 2125 S. 11th St. in Chesterton, Indiana, according to Porter County Sheriff’s Police.

Deputies and officials with the the Duneland School Corporation learned about the threat about 6:15 p.m. Sunday and started an investigation, the sheriff’s office said. Authorities ultimately determined that the threat wasn’t credible.

The boy who made the threat was enrolled at Chesterton when he posted the message to Facebook, the sheriff’s office said. He was taken to a hospital Sunday for an evaluation.

On Monday, the boy admitted to gaining access to the other student’s Facebook account through a cellphone they previously shared, the sheriff’s office said. He said he posted the message in an attempt to get the other student into trouble.

“Although I am not surprised, I am grateful all agencies were able to work together on this incident and bring it to a close so quickly,” Porter County Sheriff David Reynolds said in a statement.

“This was also due in part to the community and students that saw the post, did the right thing and alerted authorities,” Reynolds said.

The Indiana Department of Child Services is assisting the boy’s family, the sheriff’s office said. The case was passed to Porter County Juvenile Probation Court for review.

Extra patrol officers were dispatched to the school on Monday and student families were notified of the incident, the sheriff’s office said.