added user registration and login