I salute this F/O
We can always discuss what would be best to do. However I salute this First Officer for handling the situation the best he thought was possible.
We can also consider the scenario if the captain had food poisoning from hotel food or catering. The F/O might be becoming sick as well. With no access to the cockpit becaus the capt was blocking the door. I would say the F/O did excactly the right thing. However I was not there, I dont know.
Again I salute this First Officer for handling a difficult situation well.