Application quits if login is cancelled