bugfix with first-attempt login