Report error if login failed
Remove debug code