Methinks it's for a nervous pooper who doesn't like people fiddling with the knob whilst they do their business. Might even be so bad that they physically can't should it happen.Devils advocate here: When the door is locked and you can't get in. Is it not occupied?
When I moved from UK to Australia in 2003 I was surprised to see light switches and sockets in bathrooms - in some cases the sockets were next to the sink. Having now lived here 14 years, I've never come across anyone that has tripped a breaker or got a shock from these fittings. I now routinely switch them with wet hands. Makes me wonder if the UK regulations are more suited to much earlier times and not relevant now.Whatever you come up with bear safety in mind, here in the Uk the power supply would need to be Selv rated if it is within a certain distance of the bath/shower/sink/toilet.