aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Server.Implementations/Intros/DefaultIntroProvider.cs
diff options
context:
space:
mode:
authorLuke <luke.pulverenti@gmail.com>2016-08-29 15:01:00 -0400
committerGitHub <noreply@github.com>2016-08-29 15:01:00 -0400
commitd02cedb5b504ce49e76ae945fa8fe9258f9b58be (patch)
treecce3e9e041d9cd6948eae5eac0ce7a99d17887fe /MediaBrowser.Server.Implementations/Intros/DefaultIntroProvider.cs
parent1d0e341652b6b08484564a741a5eee49d5a1704d (diff)
parente8977c44857907cab171e4726db096508673735a (diff)
Merge pull request #2124 from MediaBrowser/beta
Beta
Diffstat (limited to 'MediaBrowser.Server.Implementations/Intros/DefaultIntroProvider.cs')
-rw-r--r--MediaBrowser.Server.Implementations/Intros/DefaultIntroProvider.cs9
1 files changed, 6 insertions, 3 deletions
diff --git a/MediaBrowser.Server.Implementations/Intros/DefaultIntroProvider.cs b/MediaBrowser.Server.Implementations/Intros/DefaultIntroProvider.cs
index 7c7a535cd..4a43befed 100644
--- a/MediaBrowser.Server.Implementations/Intros/DefaultIntroProvider.cs
+++ b/MediaBrowser.Server.Implementations/Intros/DefaultIntroProvider.cs
@@ -216,7 +216,8 @@ namespace MediaBrowser.Server.Implementations.Intros
}
return allIntros
- .Where(i => IsMatch(i.Path, codec));
+ .Where(i => IsMatch(i.Path, codec))
+ .OrderBy(i => Guid.NewGuid());
}
private IEnumerable<IntroInfo> GetMediaInfoIntrosByAudioStream(List<IntroInfo> allIntros, MediaStream stream)
@@ -229,13 +230,15 @@ namespace MediaBrowser.Server.Implementations.Intros
}
return allIntros
- .Where(i => IsAudioMatch(i.Path, stream));
+ .Where(i => IsAudioMatch(i.Path, stream))
+ .OrderBy(i => Guid.NewGuid());
}
private IEnumerable<IntroInfo> GetMediaInfoIntrosByTags(List<IntroInfo> allIntros, List<string> tags)
{
return allIntros
- .Where(i => tags.Any(t => IsMatch(i.Path, t)));
+ .Where(i => tags.Any(t => IsMatch(i.Path, t)))
+ .OrderBy(i => Guid.NewGuid());
}
private bool IsMatch(string file, string attribute)