aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Api/PluginService.cs
diff options
context:
space:
mode:
authorMark Monteiro <marknr.monteiro@protonmail.com>2020-04-13 17:06:24 -0400
committerMark Monteiro <marknr.monteiro@protonmail.com>2020-04-13 17:06:24 -0400
commit9728aa8b0abc7785f8c9f3d62c2adff1920cfab9 (patch)
tree111975663193ef2dfab67380e6d5a2f4f9d554f6 /MediaBrowser.Api/PluginService.cs
parent17e8813378c2fe1a83d1eddb829dae68f8c71bfe (diff)
parent9a0a4575adbba04b6b7f3294e70175a98b864a90 (diff)
Merge branch 'master' into register-services-correctly
Diffstat (limited to 'MediaBrowser.Api/PluginService.cs')
-rw-r--r--MediaBrowser.Api/PluginService.cs4
1 files changed, 1 insertions, 3 deletions
diff --git a/MediaBrowser.Api/PluginService.cs b/MediaBrowser.Api/PluginService.cs
index 16d3268b9..7f74511ee 100644
--- a/MediaBrowser.Api/PluginService.cs
+++ b/MediaBrowser.Api/PluginService.cs
@@ -243,9 +243,7 @@ namespace MediaBrowser.Api
// https://code.google.com/p/servicestack/source/browse/trunk/Common/ServiceStack.Text/ServiceStack.Text/Controller/PathInfo.cs
var id = Guid.Parse(GetPathValue(1));
- var plugin = _appHost.Plugins.First(p => p.Id == id) as IHasPluginConfiguration;
-
- if (plugin == null)
+ if (!(_appHost.Plugins.First(p => p.Id == id) is IHasPluginConfiguration plugin))
{
throw new FileNotFoundException();
}