Update stay.php and unlock device