Merge pull request #1896 from MediaBrowser/dev

Dev
This commit is contained in:
Luke 2016-06-30 15:13:44 -04:00 committed by GitHub
commit 1f037779d7
2 changed files with 7 additions and 6 deletions

View File

@ -327,7 +327,8 @@ namespace MediaBrowser.Api
MinPremiereDate = minPremiereDate, MinPremiereDate = minPremiereDate,
StartIndex = request.StartIndex, StartIndex = request.StartIndex,
Limit = request.Limit, Limit = request.Limit,
ParentId = parentIdGuid ParentId = parentIdGuid,
Recursive = true
}).ToList(); }).ToList();

View File

@ -32,9 +32,7 @@ namespace MediaBrowser.Server.Implementations.TV
throw new ArgumentException("User not found"); throw new ArgumentException("User not found");
} }
var parentIds = string.IsNullOrEmpty(request.ParentId) var parentIdGuid = string.IsNullOrWhiteSpace(request.ParentId) ? (Guid?)null : new Guid(request.ParentId);
? new string[] { }
: new[] { request.ParentId };
string presentationUniqueKey = null; string presentationUniqueKey = null;
int? limit = null; int? limit = null;
@ -54,9 +52,11 @@ namespace MediaBrowser.Server.Implementations.TV
IncludeItemTypes = new[] { typeof(Series).Name }, IncludeItemTypes = new[] { typeof(Series).Name },
SortOrder = SortOrder.Ascending, SortOrder = SortOrder.Ascending,
PresentationUniqueKey = presentationUniqueKey, PresentationUniqueKey = presentationUniqueKey,
Limit = limit Limit = limit,
ParentId = parentIdGuid,
Recursive = true
}, parentIds).Cast<Series>(); }).Cast<Series>();
// Avoid implicitly captured closure // Avoid implicitly captured closure
var episodes = GetNextUpEpisodes(request, user, items); var episodes = GetNextUpEpisodes(request, user, items);