Updated

A Florida teacher, who survived one of the worst high school shootings in U.S. history, was arrested Sunday after he left a loaded pistol in the stall of a public restroom where a homeless man found it and later fired it, police said.

Sean Simpson, 43, was at the Deerfield Beach Pier when he left the Glock 9 mm in a restroom at the area, the Broward County Sheriff’s Office said. He told officers he left the gun in the bathroom by accident.

Simpson is a science teacher at Marjory Stoneman Douglas High School in Parkland, where a gunman opened fire, killing 17 people in February. He told police he went back to get the gun and found a homeless man, Joseph Spataro, 69, who appeared to be intoxicated, had found it first, ABC News reported.

Spataro fired the gun at a wall before Simpson was able to get the gun back, police said.

b2bf5e39-sean simpson

Sean Simpson, a teacher, was arrested Sunday after leaving a loaded pistol in a public place. (Marjory Stoneman Douglas High School)

FLORIDA SCHOOL SHOOTER WANTS VICTIMS TO HAVE HIS INHERITANCE

Simpson was charged with failing to safely store a firearm, a second-degree misdemeanor, according to ABC News. The teacher posted the $250 cash bond Sunday and was released.

Spataro told police he fired the pistol to “see if it was loaded.” He was charged with “firing a weapon while intoxicated and trespassing.”

The Broward County School Board told WPLG they would most likely not seek disciplinary against the educator. Simpson told the station following the school shooting that he was willing to carry a gun in order to protect students from future attacks.

FLORIDA COP, 24, FIRED OVER ‘TERRIBLE’ RACIALLY-CHARGED SNAPCHAT POST

On Tuesday, the school board rejected the Coach Aaron Feis Guardian Program, which was named in honor of a gym teacher who gave his life to protect students during the Valentine’s Day massacre. The program would have armed school staff in the wake of the school shooting allegedly carried out by former student Nikolas Cruz.

Simpson did not immediately comment on his arrest and charges.