diff options
| author | Vasily <JustAMan@users.noreply.github.com> | 2020-01-11 02:02:48 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-01-11 02:02:48 +0300 |
| commit | aca4d678a2a6aa46b57837d3a6c1bc9d4c537d7b (patch) | |
| tree | 88f29a76eca6f3f6cdd299ad32beab5c5d36b72a /Emby.Server.Implementations/ApplicationHost.cs | |
| parent | fa1aeeb18a766fd7b2265dc0352ee100d8377163 (diff) | |
| parent | bb236b95916c7fe0fc04fefbb409686ab289a758 (diff) | |
Merge pull request #2136 from Bond-009/warn12
More warnings (removed)
Diffstat (limited to 'Emby.Server.Implementations/ApplicationHost.cs')
| -rw-r--r-- | Emby.Server.Implementations/ApplicationHost.cs | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/Emby.Server.Implementations/ApplicationHost.cs b/Emby.Server.Implementations/ApplicationHost.cs index a179c1b150..0bb1d832fb 100644 --- a/Emby.Server.Implementations/ApplicationHost.cs +++ b/Emby.Server.Implementations/ApplicationHost.cs @@ -1,4 +1,5 @@ #pragma warning disable CS1591 +#pragma warning disable SA1600 using System; using System.Collections.Concurrent; @@ -177,11 +178,7 @@ namespace Emby.Server.Implementations /// Gets the plugins. /// </summary> /// <value>The plugins.</value> - public IPlugin[] Plugins - { - get => _plugins; - protected set => _plugins = value; - } + public IReadOnlyList<IPlugin> Plugins => _plugins; /// <summary> /// Gets or sets the logger factory. @@ -1056,7 +1053,7 @@ namespace Emby.Server.Implementations } ConfigurationManager.AddParts(GetExports<IConfigurationFactory>()); - Plugins = GetExports<IPlugin>() + _plugins = GetExports<IPlugin>() .Select(LoadPlugin) .Where(i => i != null) .ToArray(); @@ -1705,9 +1702,9 @@ namespace Emby.Server.Implementations /// <param name="plugin">The plugin.</param> public void RemovePlugin(IPlugin plugin) { - var list = Plugins.ToList(); + var list = _plugins.ToList(); list.Remove(plugin); - Plugins = list.ToArray(); + _plugins = list.ToArray(); } /// <summary> |
