login and register functionality added