state control for door open

was easier to control condition