Updates login function.