Updated to handle bad logins.