diff options
| author | Bond-009 <bond.009@outlook.com> | 2019-12-17 17:35:27 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-12-17 17:35:27 +0100 |
| commit | 6b185119aa329764c1ccc57d9be3e81f05680b69 (patch) | |
| tree | a2dd354a5a55ed9669750ede3f7c00baae4f09be /MediaBrowser.Api/PluginService.cs | |
| parent | 35151553e3fc9ddbe352744af8d832b1337491c8 (diff) | |
| parent | db61a58c39490f86c86c3ee6c6f11743796fb10e (diff) | |
Merge branch 'master' into namingtests
Diffstat (limited to 'MediaBrowser.Api/PluginService.cs')
| -rw-r--r-- | MediaBrowser.Api/PluginService.cs | 27 |
1 files changed, 10 insertions, 17 deletions
diff --git a/MediaBrowser.Api/PluginService.cs b/MediaBrowser.Api/PluginService.cs index af61887b2..16d3268b9 100644 --- a/MediaBrowser.Api/PluginService.cs +++ b/MediaBrowser.Api/PluginService.cs @@ -3,14 +3,14 @@ using System.IO; using System.Linq; using System.Threading.Tasks; using MediaBrowser.Common; -using MediaBrowser.Common.Net; using MediaBrowser.Common.Plugins; using MediaBrowser.Common.Updates; -using MediaBrowser.Controller.Devices; +using MediaBrowser.Controller.Configuration; using MediaBrowser.Controller.Net; using MediaBrowser.Model.Plugins; using MediaBrowser.Model.Serialization; using MediaBrowser.Model.Services; +using Microsoft.Extensions.Logging; namespace MediaBrowser.Api { @@ -150,25 +150,18 @@ namespace MediaBrowser.Api /// </summary> private readonly IApplicationHost _appHost; private readonly IInstallationManager _installationManager; - private readonly INetworkManager _network; - private readonly IDeviceManager _deviceManager; - public PluginService(IJsonSerializer jsonSerializer, + public PluginService( + ILogger<PluginService> logger, + IServerConfigurationManager serverConfigurationManager, + IHttpResultFactory httpResultFactory, + IJsonSerializer jsonSerializer, IApplicationHost appHost, - IInstallationManager installationManager, - INetworkManager network, - IDeviceManager deviceManager) - : base() + IInstallationManager installationManager) + : base(logger, serverConfigurationManager, httpResultFactory) { - if (jsonSerializer == null) - { - throw new ArgumentNullException(nameof(jsonSerializer)); - } - _appHost = appHost; _installationManager = installationManager; - _network = network; - _deviceManager = deviceManager; _jsonSerializer = jsonSerializer; } @@ -248,7 +241,7 @@ namespace MediaBrowser.Api { // We need to parse this manually because we told service stack not to with IRequiresRequestStream // https://code.google.com/p/servicestack/source/browse/trunk/Common/ServiceStack.Text/ServiceStack.Text/Controller/PathInfo.cs - var id = new Guid(GetPathValue(1)); + var id = Guid.Parse(GetPathValue(1)); var plugin = _appHost.Plugins.First(p => p.Id == id) as IHasPluginConfiguration; |
