From 664bcadbad0c05a60d83f5b8e24801534643a5e1 Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Tue, 17 Nov 2015 11:37:16 -0500 Subject: update cinema mode config page --- .../Intros/DefaultIntroProvider.cs | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) (limited to 'MediaBrowser.Server.Implementations/Intros/DefaultIntroProvider.cs') diff --git a/MediaBrowser.Server.Implementations/Intros/DefaultIntroProvider.cs b/MediaBrowser.Server.Implementations/Intros/DefaultIntroProvider.cs index e17739d535..2228455c1a 100644 --- a/MediaBrowser.Server.Implementations/Intros/DefaultIntroProvider.cs +++ b/MediaBrowser.Server.Implementations/Intros/DefaultIntroProvider.cs @@ -237,13 +237,21 @@ namespace MediaBrowser.Server.Implementations.Intros { options = options ?? GetOptions(); - if (string.IsNullOrWhiteSpace(options.CustomIntroPath)) + var list = new List(); + + if (!string.IsNullOrWhiteSpace(options.CustomIntroPath)) { - return new List(); + list.AddRange(_fileSystem.GetFilePaths(options.CustomIntroPath, true) + .Where(_libraryManager.IsVideoFile)); } - return _fileSystem.GetFilePaths(options.CustomIntroPath, true) - .Where(_libraryManager.IsVideoFile); + if (!string.IsNullOrWhiteSpace(options.CodecIntroPath)) + { + list.AddRange(_fileSystem.GetFilePaths(options.CodecIntroPath, true) + .Where(_libraryManager.IsVideoFile)); + } + + return list.Distinct(StringComparer.OrdinalIgnoreCase); } private bool FilterByParentalRating(int? ratingLevel, BaseItem item) -- cgit v1.2.3