aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2016-10-27 23:16:38 -0400
committerLuke Pulverenti <luke.pulverenti@gmail.com>2016-10-27 23:16:38 -0400
commitf6acc5fbff081728138564867a58b7848c92c467 (patch)
treeb9e1fb9164bf08c1032d841e832113673d97320d
parent8030370cfad2fe3426f7c178407af1ffca8c9abc (diff)
exclude defunct assemblies
-rw-r--r--MediaBrowser.Server.Startup.Common/ApplicationHost.cs14
1 files changed, 14 insertions, 0 deletions
diff --git a/MediaBrowser.Server.Startup.Common/ApplicationHost.cs b/MediaBrowser.Server.Startup.Common/ApplicationHost.cs
index 8dbc90429..9011f0bf5 100644
--- a/MediaBrowser.Server.Startup.Common/ApplicationHost.cs
+++ b/MediaBrowser.Server.Startup.Common/ApplicationHost.cs
@@ -1273,6 +1273,7 @@ namespace MediaBrowser.Server.Startup.Common
try
{
return Directory.EnumerateFiles(ApplicationPaths.PluginsPath, "*.dll", SearchOption.TopDirectoryOnly)
+ .Where(EnablePlugin)
.Select(LoadAssembly)
.Where(a => a != null)
.ToList();
@@ -1283,6 +1284,19 @@ namespace MediaBrowser.Server.Startup.Common
}
}
+ private bool EnablePlugin(string path)
+ {
+ var filename = Path.GetFileName(path);
+
+ var exclude = new[]
+ {
+ "mbplus.dll",
+ "mbintros.dll"
+ };
+
+ return !exclude.Contains(filename ?? string.Empty, StringComparer.OrdinalIgnoreCase);
+ }
+
/// <summary>
/// Gets the system status.
/// </summary>