Added login functionality when a user signs up.(Auto-login on signup)