Esempio n. 1
0
        //if the credential exist create session and return true
        //else return false
        public bool IsUserExist(UserModel userModel)
        {
            User user = new User
            {
                UserName = userModel.UserName,
                Password = userModel.Password
            };

            if (homeRepository.UserFound(user).Any())
            {
                homeRepository.CreateUserSession(user);
                return(true);
            }
            return(false);
        }