Better error messages in login code.