update: register and login