more of the login logic...