Merge pull request #596 from miniduikboot/fix/cleanup-disposed-clients

Clean up clients that refuse to quit properly
This commit is contained in:
miniduikboot authored and GitHub committed 2024-05-30 21:47:31 +02:00
commit 734643c8c9
1 file changed
+1 -1
+1 -1
View File
@@ -81,7 +81,7 @@ namespace Impostor.Server.Net.State
if (player.Client.Connection.IsConnected && player.Client.Connection is HazelConnection hazel)
{
_logger.LogInformation("{0} - Player {1} ({2}) kept connection open after leaving, disposing.", Code, player.Client.Name, playerId);
hazel.DisposeInnerConnection();
await player.Client.DisconnectAsync(isBan ? DisconnectReason.Banned : DisconnectReason.Kicked);
}
});