Relax, this was commonly done in baby swimming lessons in Switzerland. Not that big of a deal
If it's not OK to hit an adult with a stick, it's not OK to hit a child with a stick! And it boggles my mind that this requires explanation.
However, reading up on that now, the fun thing seems to be that no one can reliably tell when that reflex stops. Could be a few months, could be just a few weeks, so the recommendation is to just not do it. TIL. In any case, throwing a child in the water should just not be done. Period.