public UserModel GetUser(string userName) { MYUser user = _userRepoistory.GetByName(userName); if (user == null) { return(null); } else { UserModel userModel = new UserModel(); userModel.Id = user.id; userModel.MD5Password = user.Password; return(userModel); } }
public bool HasExist(string userName) { return(_userRepoistory.GetByName(userName) != null); }