using Ardalis.Specification; using BeReadyBackend.Models; namespace BeReadyBackend.Specifications.Users; public class GetProofOrChallengeByUserIdSpec : SingleResultSpecification { public GetProofOrChallengeByUserIdSpec(int userId) { Query .Include(x => x.UserRandomChallenges!) .ThenInclude(x => x.RandomChallenge) .Where(x => x.Id == userId); } }