A high school in Matthews, North Carolina, resumed classes on Monday after one student fatally shot another because officials said they thought it was the safest course for the kids.

Butler High School’s announcement that classes would proceed just hours after the deadly shooting on campus drew backlash, however, from students, parents and activists online.

Clayton Wilcox, superintendent of Charlotte-Mecklenburg Schools, defended the decision at a press conference Monday afternoon.

“I want to clarify that our decision to keep students on campus and in class was motivated by one goal, and that’s to keep our students safe until transportation could be arranged with their families,” Wilcox told reporters.

He continued: “I want to ask each of you who are here to consider for just one moment what would have happened had we just let kids run off into the neighborhood. For parents who were worried about their children, what would they have said to us if they would have come to school and we couldn’t locate their children? I think their fear would have been magnified. ... The plan that we had in place when an active shooter was on the campus was effectuated and it was effective.”

Butler High, which is located roughly 12 miles southeast of Charlotte, went into lockdown around 7 a.m. Monday after a male student fired a gun at another male student during a disagreement in a crowded hallway, officials said.

The victim, identified as 16-year-old sophomore Bobby McKeithen, was transported to a hospital, where he later died of his injuries, officials said. The suspected shooter, 16-year-old freshman Jatwan Cuffie, was taken into custody and questioned by police. He has been charged with first-degree murder.

Wilcox described the confrontation between the two students as “a bullying incident gone out of control.”

By 9:30 a.m., Charlotte-Mecklenburg Schools announced that the lockdown was lifted. Parents were allowed to pick up their children, but for the remaining students, classes remained in session, the school district tweeted.

Although only a small number of students remained on campus by 1 p.m., teachers were instructed to finish out the day, Tracy Russ, chief communications officer for Charlotte-Mecklenburg Schools, told HuffPost.

“Classes remained in session so that we could keep students on campus while transportation arrangements were being made,” Russ explained.

An armed school resource officer was on duty at the time of the incident, but it’s unclear whether he engaged the shooter, Russ told HuffPost. The school, which does not have metal detectors, plans to review its safety protocols in the wake of the shooting, he said.

“This is a tragic event,” Russ said. “It is an event that will require support from the entire community of students and family and staff. ... There will be a great deal of healing taking place in the coming days and weeks.”

Counseling is available to students and staff members in the wake of the shooting, the school district tweeted. Butler High classes have been canceled for Tuesday and Wednesday, Wilcox said at the press conference.

“We are going to give the teachers an opportunity to process what they’ve been through and we will give students an opportunity to stay home with family and loved ones and come to grips with what took place today,” he said.”

The school district’s earlier announcement that classes would proceed on Monday had drawn strong reactions on Twitter.

“This is nightmarish,” tweeted Cameron Kasky, a survivor of the deadly mass shooting at Marjory Stoneman Douglas High School in Parkland, Florida, on Feb. 14.