Added sign in logic