Minor fixes in user authentication.