fixing closing the login form