It costs nothing to have a cabin crew member go into the flight deck when one of the flight crew needs to leave and it provides a level of protection should the remaining pilot suffer from some sought of collapse.
Now possibly allowing a deranged flight attendant in on the cockpit when it is most vulnerable.
Where does it end.