fix the login, get username and userId