Merge branch 'develop-test' of https://github.com/tidusjar/Ombi into develop-test

pull/4003/head
twanariens 4 years ago
commit 9f28b3eedf

@ -27,4 +27,4 @@ variables:
value: "4.0.$(Build.BuildId)"
- name: isMain
value: $[or(contains(variables['Build.SourceBranch'], 'develop'), contains(variables['Build.SourceBranch'], 'main'))]
value: $[or(eq(variables['Build.SourceBranch'], 'refs/heads/develop'), eq(variables['Build.SourceBranch'], 'refs/heads/main'))]

@ -22,21 +22,21 @@ namespace Ombi.Store.Repository.Requests
{
return await Db.TvRequests.Where(x => x.TvDbId == tvDbId)
.Include(x => x.ChildRequests)
.ThenInclude(x => x.RequestedUser)
.ThenInclude(x => x.RequestedUser)
.Include(x => x.ChildRequests)
.ThenInclude(x => x.SeasonRequests)
.ThenInclude(x => x.Episodes)
.ThenInclude(x => x.SeasonRequests)
.ThenInclude(x => x.Episodes)
.FirstOrDefaultAsync();
}
public TvRequests GetRequest(int tvDbId)
{
return Db.TvRequests.Where(x => x.TvDbId == tvDbId)
return Db.TvRequests.Where(x => x.TvDbId == tvDbId).AsSplitQuery()
.Include(x => x.ChildRequests)
.ThenInclude(x => x.RequestedUser)
.ThenInclude(x => x.RequestedUser)
.Include(x => x.ChildRequests)
.ThenInclude(x => x.SeasonRequests)
.ThenInclude(x => x.Episodes)
.ThenInclude(x => x.SeasonRequests)
.ThenInclude(x => x.Episodes)
.FirstOrDefault();
}

Loading…
Cancel
Save