fixed problem with login view not closing