This video explains how the cockpit door in airplanes work. In case of a medical emergency it can always be opened.

https://www.youtube.com/watch?t=138&v=ixEHV7c3VXs


EDIT: Just confirmed by...