public async Task <User> FilterAsync(UserResetCodeModel model) { Guid?code = GetGuidCode(model.Code); if (code.HasValue) { return(await Collection.Find(ByResetCode(code.Value.ToString())).SingleOrDefaultAsync()); } return(null); }
public User Filter(UserResetCodeModel model) { Guid?code = GetGuidCode(model.Code); if (code.HasValue) { return(Collection.Find(ByResetCode(code.Value.ToString())).SingleOrDefault()); } return(null); }