Fix sign in functionality