fixed login to properly realize invalid logins