update login functionality