If one pilot wanted a pee, the other pilot (the nutty one) could then re-enter the f/d and lock door.
.......
Ahhh ha.. got the answer to that one -station a heavily armed guard outside the flight deck door with instruction not to let anyone in on their own..are we all feeling safer yet?
I can see a flaw in your cunning plan, what if both pilots forget the key code for the door ?
OOOh yeahh
I'll stop now before I get told to sit on the naughty step....