Revert "Removed Lazy implementation."

This commit is contained in:
cvium
2020-11-28 09:50:16 +01:00
parent 5cd5a7d4ce
commit 1a0d8aef80
12 changed files with 64 additions and 95 deletions

View File

@@ -25,10 +25,19 @@ namespace Jellyfin.Server.Middleware
/// </summary>
/// <param name="httpContext">The current HTTP context.</param>
/// <param name="webSocketManager">The WebSocket connection manager.</param>
/// <param name="websocketListener">Session manager instance.</param>
/// <returns>The async task.</returns>
public async Task Invoke(
HttpContext httpContext,
IWebSocketManager webSocketManager)
IWebSocketManager webSocketManager,
#pragma warning disable CA1801
#pragma warning disable IDE0060
// TODO: Workaround. see https://github.com/jellyfin/jellyfin/pull/3194
// Do not remove this parameter. It uses DI to create a SessionWebSocketListener which is
// required for webSocketManager events.
IWebSocketListener websocketListener)
#pragma warning restore IDE0060 // Remove unused parameter
#pragma warning restore CA1801
{
if (!httpContext.WebSockets.IsWebSocketRequest)
{