diff options
| author | Claus Vium <clausvium@gmail.com> | 2019-03-06 19:27:05 +0100 |
|---|---|---|
| committer | Claus Vium <clausvium@gmail.com> | 2019-03-06 19:27:05 +0100 |
| commit | 21c2acc520bcebe74dacc4caf1c244e258a12aec (patch) | |
| tree | 7b85fd8b36622cd6d65f53b93c849b8f0f49461d | |
| parent | 394d23a73a530b5ce2609d01575e0ced734aecfe (diff) | |
Remove public Host property
| -rw-r--r-- | Emby.Server.Implementations/ApplicationHost.cs | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/Emby.Server.Implementations/ApplicationHost.cs b/Emby.Server.Implementations/ApplicationHost.cs index 93147539c..71a112dac 100644 --- a/Emby.Server.Implementations/ApplicationHost.cs +++ b/Emby.Server.Implementations/ApplicationHost.cs @@ -129,7 +129,7 @@ namespace Emby.Server.Implementations /// </summary> /// <value><c>true</c> if this instance can self restart; otherwise, <c>false</c>.</value> public abstract bool CanSelfRestart { get; } - public IWebHost Host { get; set; } + public virtual bool CanLaunchWebBrowser { get @@ -625,7 +625,7 @@ namespace Emby.Server.Implementations contentRoot = Path.Combine(ServerConfigurationManager.ApplicationPaths.ApplicationResourcesPath, "jellyfin-web", "src"); } - Host = new WebHostBuilder() + var host = new WebHostBuilder() .UseKestrel(options => { options.ListenAnyIP(HttpPort); @@ -652,10 +652,10 @@ namespace Emby.Server.Implementations }) .Build(); - await Host.StartAsync(); + await host.StartAsync(); } - public async Task ExecuteWebsocketHandlerAsync(HttpContext context, Func<Task> next) + private async Task ExecuteWebsocketHandlerAsync(HttpContext context, Func<Task> next) { if (!context.WebSockets.IsWebSocketRequest) { @@ -665,7 +665,8 @@ namespace Emby.Server.Implementations await HttpServer.ProcessWebSocketRequest(context).ConfigureAwait(false); } - public async Task ExecuteHttpHandlerAsync(HttpContext context, Func<Task> next) + + private async Task ExecuteHttpHandlerAsync(HttpContext context, Func<Task> next) { if (context.WebSockets.IsWebSocketRequest) { |
