If you’re scared of someone outside a locked door, the correct response is NOT to open said door to defend your door (whether you’re armed or not).
We have police officers for a reason.