|
|
@ -102,10 +102,15 @@ namespace MediaBrowser.Server.Implementations.Intros
|
|
|
|
|
|
|
|
|
|
|
|
if (trailerTypes.Count > 0)
|
|
|
|
if (trailerTypes.Count > 0)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
var excludeTrailerTypes = Enum.GetNames(typeof(TrailerType))
|
|
|
|
|
|
|
|
.Select(i => (TrailerType)Enum.Parse(typeof(TrailerType), i, true))
|
|
|
|
|
|
|
|
.Except(trailerTypes)
|
|
|
|
|
|
|
|
.ToArray();
|
|
|
|
|
|
|
|
|
|
|
|
var trailerResult = _libraryManager.GetItemList(new InternalItemsQuery
|
|
|
|
var trailerResult = _libraryManager.GetItemList(new InternalItemsQuery
|
|
|
|
{
|
|
|
|
{
|
|
|
|
IncludeItemTypes = new[] { typeof(Trailer).Name },
|
|
|
|
IncludeItemTypes = new[] { typeof(Trailer).Name },
|
|
|
|
TrailerTypes = trailerTypes.ToArray()
|
|
|
|
ExcludeTrailerTypes = excludeTrailerTypes
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
candidates.AddRange(trailerResult.Select(i => new ItemWithTrailer
|
|
|
|
candidates.AddRange(trailerResult.Select(i => new ItemWithTrailer
|
|
|
|