It reads as if the first time (of two) it was stuck this way. So, for some reason you tried playing around
again with the lock?! Come on.
In any case, on behalf of British train users, please stop occupying the toilet needlessly and playing with the door locks. What happens if you or the next person gets locked in there? What happens if someone thinks you're being suspicious and calls the transport police? The services are delayed enough as it is.