Anthony Wheeler, who made an online threat against his classmates while he was a student at ConVal Regional High School, walks away with his attorney, Justin Shepherd, at Hillsborough County Superior Court in Manchester on Friday, May 3, 2019.

MANCHESTER — Teenager Anthony Wheeler posted an online photo of a friend wearing a black trench coat, fedora, orange goggles and holding “two very realistic-looking firearms,” a county prosecutor said Friday.

That photo — along with a warning for fellow students at ConVal Regional High School to avoid going to school — canceled classes last November, landed Wheeler in jail for 79 days and resulted in him receiving a suspended sentence Friday.

“I understand that what I did scared many people and caused inconvenience for many others,” Wheeler said in an interview following his sentencing.

Wheeler, 19, formerly of Antrim, agreed to a plea deal that gave him a 12-month suspended sentence after facing two felony charges that could have landed him in prison for up to 14 years if convicted.

“Do you understand how serious this issue was, the fear that sort of exists in school systems throughout the country due to the outrageous number of shooting incidents that has happened at schools in recent history?” asked Judge David Anderson in Hillsborough County Superior Court North.

Anderson said he harbored some reluctance to accept the guilty plea for a misdemeanor criminal threatening charge, but the judge said he respected the community’s response since prosecutors consulted police and school officials.

Wheeler, who was expelled from ConVal, didn’t finish high school and works at a Massachusetts landscaping job near where he lives.

“It was a bad joke that got out of control,” Wheeler’s mother, Tiffany, said after the hearing.

The teen said his photo was posted to a closed group of friends on Snapchat with 100 people maximum.

His mother criticized school officials for canceling classes.

“They still proceeded to cancel school and all of that fully knowing it was a joke,” she said.

“He deserved to be punished,” she said. “I’m his mother and I’ll tell you straight out what he did was wrong and he is very lucky he only got what he got.”

ConVal superintendent Kimberly Rizzo Saunders didn’t return a phone message left at her office.

Anthony Wheeler said he missed his family during his 79 days at the Valley Street jail.

“You don’t really think about yourself,” he said. “You’re more worried about the loved ones that you can’t see, that you can’t talk to,” he said.

Wheeler said he’s learned “to think before I act first of all — that not everything can be taken as a joke; some things should be taken more seriously.”

This marks the second case in Hillsborough County Superior Court this year involving school threats.

A Hillsborough man who made comments about bringing a gun to his graduation for Hillsboro-Deering High School spent eight months in jail awaiting trial.

After two days of testimony, a Hillsborough County jury in February took less than an hour to find John Thomas, 18, not guilty of several charges, including solicitation to commit murder.

“The County Attorney’s office, working in concert with local police departments, will never ignore what is perceived to be a threat in our community,” Hillsborough County Attorney Michael Conlon said after the Thomas verdict.