diff options
| author | Vasily <JustAMan@users.noreply.github.com> | 2019-02-20 14:46:07 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-02-20 14:46:07 +0300 |
| commit | bca7a26ffd84b14a9186082656fb66f891ccd27f (patch) | |
| tree | b927f6d7be92d805e610514f45762f5900c61b6d /Emby.Server.Implementations/HttpServer/HttpListenerHost.cs | |
| parent | 1f30a50f4a361be303c9221d9d3e5c4d8db2b364 (diff) | |
| parent | 60df855b263e691f946973a192621e7998db9cbb (diff) | |
Merge branch 'master' into update_tvdb
Diffstat (limited to 'Emby.Server.Implementations/HttpServer/HttpListenerHost.cs')
| -rw-r--r-- | Emby.Server.Implementations/HttpServer/HttpListenerHost.cs | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/Emby.Server.Implementations/HttpServer/HttpListenerHost.cs b/Emby.Server.Implementations/HttpServer/HttpListenerHost.cs index 834ffb130..d78891ac7 100644 --- a/Emby.Server.Implementations/HttpServer/HttpListenerHost.cs +++ b/Emby.Server.Implementations/HttpServer/HttpListenerHost.cs @@ -19,7 +19,9 @@ using MediaBrowser.Model.Events; using MediaBrowser.Model.Extensions; using MediaBrowser.Model.Serialization; using MediaBrowser.Model.Services; +using Microsoft.Extensions.Configuration; using Microsoft.Extensions.Logging; +using ServiceStack.Text.Jsv; namespace Emby.Server.Implementations.HttpServer { @@ -53,20 +55,20 @@ namespace Emby.Server.Implementations.HttpServer IServerApplicationHost applicationHost, ILoggerFactory loggerFactory, IServerConfigurationManager config, - string defaultRedirectPath, + IConfiguration configuration, INetworkManager networkManager, IJsonSerializer jsonSerializer, - IXmlSerializer xmlSerializer, - Func<Type, Func<string, object>> funcParseFn) + IXmlSerializer xmlSerializer) { _appHost = applicationHost; _logger = loggerFactory.CreateLogger("HttpServer"); _config = config; - DefaultRedirectPath = defaultRedirectPath; + DefaultRedirectPath = configuration["HttpListenerHost:DefaultRedirectPath"]; _networkManager = networkManager; _jsonSerializer = jsonSerializer; _xmlSerializer = xmlSerializer; - _funcParseFn = funcParseFn; + + _funcParseFn = t => s => JsvReader.GetParseFn(t)(s); Instance = this; ResponseFilters = Array.Empty<Action<IRequest, IResponse, object>>(); |
