What's wrong with calling a FA into the cockpit when the pilot needs to have a leak?
I believe some companies do just this, but only so there's someone available to open the flight deck door to let the other bloke back if the PF goes U/S.
If the second body on the flight deck isn't familiar with the operation of the aircraft, how are they going to recognise when the PF is up to no good, let alone do anything about it? Especially if we use an FA as an example, who could well be a young lady of small build with potentially half the body mass of the ne'er-do-well pilot.