From d5284ae226601b843ea0143e7c9bb80331623c51 Mon Sep 17 00:00:00 2001 From: LevelX2 Date: Tue, 5 Sep 2017 16:58:06 +0200 Subject: [PATCH] Fixed that some user data was not cleared as a user was disconnected. --- Mage.Server/src/main/java/mage/server/User.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Mage.Server/src/main/java/mage/server/User.java b/Mage.Server/src/main/java/mage/server/User.java index 985b8fc708..e1f0abd8fd 100644 --- a/Mage.Server/src/main/java/mage/server/User.java +++ b/Mage.Server/src/main/java/mage/server/User.java @@ -388,7 +388,7 @@ public class User { } else { // Table is missing after connection was lost during sideboard. // Means other players were removed or conceded the game? - logger.error("sideboarding id not found : " + entry.getKey()); + logger.debug(getName() + " reconnects during sideboarding but tableId not found: " + entry.getKey()); } } ServerMessagesUtil.instance.incReconnects(); @@ -450,12 +450,14 @@ public class User { TournamentManager.instance.quit(tournamentId, userId); } userTournaments.clear(); + constructing.clear(); logger.trace("REMOVE " + userName + " Tables " + tables.size()); for (Entry entry : tables.entrySet()) { logger.debug("-- leave tableId: " + entry.getValue().getId()); TableManager.instance.leaveTable(userId, entry.getValue().getId()); } tables.clear(); + sideboarding.clear(); logger.trace("REMOVE " + userName + " Game sessions: " + gameSessions.size()); for (GameSessionPlayer gameSessionPlayer : gameSessions.values()) { logger.debug("-- kill game session of gameId: " + gameSessionPlayer.getGameId());