Fixed bug where authentication failed to refresh  when user logged in with incorrect credentials, then logged in again with correct creds