Fixed user updating. Added login pre-auth code