I would email the teacher and the Principal and let them know that if they pull a stunt like that again that you will take it over their head to the Dept of Education.
There is a clear guideline that is in place for a good reason. The teacher broke the guideline and the Principal has failed to take this seriously. This is a breach of their duty of care towards their students.
You have every right to be furious. The school has let you and your son down.