Fingerprint door lock

I have make a fingerprint door lock using arduino uno and a 5 volt relay but when arduino turn off and then turn on the door open automatically like a latch can i have some solution for this problem

Don’t turn the Arduino off.

I guess the forum attracts a lot of Numb Skulls which in turn switches off the bright skulls and promotes sarcasm.
---- Use a lock control pin that stays low from boot-to-code.
---- Keep it low with a suitable resistor.
---- Only have it go high when door is to be latched.
---- A number of pins change state on boot, or can float high with a number of reasons, depending on mcu.
---- Check data sheet for pin behavior on boot.
---- Don't use a logic low for latching door.
---- Scope the Pin from mcu to latch control to see whats happening!
---- Also check if the fingerprint sensor is sending a switch logic on power up if so delay any action from sensor.

If you need more help post a schematic and code.
Read BallScrewBobs forum guidence and use. It can help in getting more precise and polite answers .... Sometimes!