diff options
| author | Cody Robibero <cody@robibe.ro> | 2022-05-29 08:49:50 -0600 |
|---|---|---|
| committer | crobibero <cody@robibe.ro> | 2022-06-06 09:16:11 -0400 |
| commit | b8722d02a37a9c1141ea7ca3391fbe795ff1bc5a (patch) | |
| tree | 69f6804247eaba2e5bc420f6712fe2911df1e6ab /Emby.Server.Implementations/Session/WebSocketController.cs | |
| parent | ad1e554141b26b36f4fac987f011ce0d7c9b73dd (diff) | |
Merge pull request #7781 from crobibero/live-tv-infinite
(cherry picked from commit 77c73e241fe1705528e3ffbb42f074c46240b9fb)
Signed-off-by: crobibero <cody@robibe.ro>
Diffstat (limited to 'Emby.Server.Implementations/Session/WebSocketController.cs')
| -rw-r--r-- | Emby.Server.Implementations/Session/WebSocketController.cs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Emby.Server.Implementations/Session/WebSocketController.cs b/Emby.Server.Implementations/Session/WebSocketController.cs index 9fa92a53a..d21b6a929 100644 --- a/Emby.Server.Implementations/Session/WebSocketController.cs +++ b/Emby.Server.Implementations/Session/WebSocketController.cs @@ -53,13 +53,13 @@ namespace Emby.Server.Implementations.Session connection.Closed += OnConnectionClosed; } - private void OnConnectionClosed(object? sender, EventArgs e) + private async void OnConnectionClosed(object? sender, EventArgs e) { var connection = sender as IWebSocketConnection ?? throw new ArgumentException($"{nameof(sender)} is not of type {nameof(IWebSocketConnection)}", nameof(sender)); _logger.LogDebug("Removing websocket from session {Session}", _session.Id); _sockets.Remove(connection); connection.Closed -= OnConnectionClosed; - _sessionManager.CloseIfNeeded(_session); + await _sessionManager.CloseIfNeededAsync(_session).ConfigureAwait(false); } /// <inheritdoc /> |
