diff options
| author | Erwin de Haan <EraYaN@users.noreply.github.com> | 2019-01-15 17:34:39 +0100 |
|---|---|---|
| committer | Erwin de Haan <EraYaN@users.noreply.github.com> | 2019-01-15 17:34:39 +0100 |
| commit | 49b61f238e634e8b2ed4af8a3e0036080cd023a6 (patch) | |
| tree | a12641849c607a3ec819b87d48481f0c5c525e1c /Emby.Server.Implementations/Updates/InstallationManager.cs | |
| parent | 9c4239af01fca7c22fbf2bdc9c97af182f858bf2 (diff) | |
| parent | 99acf83dfafedd3f426cf3ddf0de8bf58cdea86d (diff) | |
Merge branch 'dev' into reformat
# Conflicts:
# Emby.Server.Implementations/ApplicationHost.cs
# Emby.Server.Implementations/LiveTv/EmbyTV/EmbyTV.cs
# Emby.Server.Implementations/LiveTv/LiveTvManager.cs
# Emby.Server.Implementations/Security/MBLicenseFile.cs
# Emby.Server.Implementations/Security/PluginSecurityManager.cs
# Emby.Server.Implementations/Security/RegRecord.cs
# MediaBrowser.Api/PluginService.cs
# MediaBrowser.Api/System/SystemService.cs
# MediaBrowser.Common/Security/IRequiresRegistration.cs
# MediaBrowser.Common/Security/ISecurityManager.cs
# MediaBrowser.Common/Security/PaymentRequiredException.cs
# MediaBrowser.Model/Entities/MBRegistrationRecord.cs
# MediaBrowser.Model/Entities/PluginSecurityInfo.cs
# deployment/win-generic/build-jellyfin.ps1
Diffstat (limited to 'Emby.Server.Implementations/Updates/InstallationManager.cs')
| -rw-r--r-- | Emby.Server.Implementations/Updates/InstallationManager.cs | 51 |
1 files changed, 13 insertions, 38 deletions
diff --git a/Emby.Server.Implementations/Updates/InstallationManager.cs b/Emby.Server.Implementations/Updates/InstallationManager.cs index 6ed6f127b..6e69ecb56 100644 --- a/Emby.Server.Implementations/Updates/InstallationManager.cs +++ b/Emby.Server.Implementations/Updates/InstallationManager.cs @@ -10,7 +10,6 @@ using MediaBrowser.Common.Configuration; using MediaBrowser.Common.Net; using MediaBrowser.Common.Plugins; using MediaBrowser.Common.Progress; -using MediaBrowser.Common.Security; using MediaBrowser.Common.Updates; using MediaBrowser.Controller.Configuration; using MediaBrowser.Model.Cryptography; @@ -107,7 +106,6 @@ namespace Emby.Server.Implementations.Updates private readonly IApplicationPaths _appPaths; private readonly IHttpClient _httpClient; private readonly IJsonSerializer _jsonSerializer; - private readonly ISecurityManager _securityManager; private readonly IServerConfigurationManager _config; private readonly IFileSystem _fileSystem; @@ -122,7 +120,16 @@ namespace Emby.Server.Implementations.Updates // netframework or netcore private readonly string _packageRuntime; - public InstallationManager(ILogger logger, IApplicationHost appHost, IApplicationPaths appPaths, IHttpClient httpClient, IJsonSerializer jsonSerializer, ISecurityManager securityManager, IServerConfigurationManager config, IFileSystem fileSystem, ICryptoProvider cryptographyProvider, string packageRuntime) + public InstallationManager( + ILogger logger, + IApplicationHost appHost, + IApplicationPaths appPaths, + IHttpClient httpClient, + IJsonSerializer jsonSerializer, + IServerConfigurationManager config, + IFileSystem fileSystem, + ICryptoProvider cryptographyProvider, + string packageRuntime) { if (logger == null) { @@ -136,7 +143,6 @@ namespace Emby.Server.Implementations.Updates _appPaths = appPaths; _httpClient = httpClient; _jsonSerializer = jsonSerializer; - _securityManager = securityManager; _config = config; _fileSystem = fileSystem; _cryptographyProvider = cryptographyProvider; @@ -163,41 +169,10 @@ namespace Emby.Server.Implementations.Updates string packageType = null, Version applicationVersion = null) { - if (withRegistration) - { - var data = new Dictionary<string, string> - { - { "key", _securityManager.SupporterKey }, - { "mac", _applicationHost.SystemId }, - { "systemid", _applicationHost.SystemId } - }; - - var options = new HttpRequestOptions - { - Url = "https://www.mb3admin.local/admin/service/package/retrieveall?includeAllRuntimes=true", - CancellationToken = cancellationToken - }; - - options.SetPostData(data); - - using (var response = await _httpClient.SendAsync(options, "POST").ConfigureAwait(false)) - { - using (var json = response.Content) - { - cancellationToken.ThrowIfCancellationRequested(); + // TODO cvium: when plugins get back this would need to be fixed + // var packages = await GetAvailablePackagesWithoutRegistrationInfo(cancellationToken).ConfigureAwait(false); - var packages = await _jsonSerializer.DeserializeFromStreamAsync<PackageInfo[]>(json).ConfigureAwait(false); - - return FilterPackages(packages, packageType, applicationVersion); - } - } - } - else - { - var packages = await GetAvailablePackagesWithoutRegistrationInfo(cancellationToken).ConfigureAwait(false); - - return FilterPackages(packages, packageType, applicationVersion); - } + return new List<PackageInfo>(); //FilterPackages(packages, packageType, applicationVersion); } /// <summary> |
