diff --git a/Mage.Common/src/mage/view/SeatView.java b/Mage.Common/src/mage/view/SeatView.java index 6dfe92651a..49d53db091 100644 --- a/Mage.Common/src/mage/view/SeatView.java +++ b/Mage.Common/src/mage/view/SeatView.java @@ -55,7 +55,7 @@ public class SeatView implements Serializable { this.history = ""; } else { this.flagName = seat.getPlayer().getUserData().getFlagName(); - this.history = seat.getPlayer().getUserData().getMatchHistory() + " " + seat.getPlayer().getUserData().getTourneyHistory(); + this.history = seat.getPlayer().getUserData().getHistory(); } } else { // Empty seat diff --git a/Mage.Server/src/main/java/mage/server/User.java b/Mage.Server/src/main/java/mage/server/User.java index 903d4bef60..8a48715539 100644 --- a/Mage.Server/src/main/java/mage/server/User.java +++ b/Mage.Server/src/main/java/mage/server/User.java @@ -551,6 +551,11 @@ public class User { return ""; } + public static String userStatsToHistory(ResultProtos.UserStatsProto proto) { + return "Matches:" + userStatsToMatchHistory(proto) + + " Tourneys: " + userStatsToTourneyHistory(proto); + } + public static String userStatsToMatchHistory(ResultProtos.UserStatsProto proto) { StringBuilder builder = new StringBuilder(); builder.append(proto.getMatches()); diff --git a/Mage.Server/src/main/java/mage/server/UserManager.java b/Mage.Server/src/main/java/mage/server/UserManager.java index a32307b80c..cc33fd001a 100644 --- a/Mage.Server/src/main/java/mage/server/UserManager.java +++ b/Mage.Server/src/main/java/mage/server/UserManager.java @@ -205,9 +205,9 @@ public class UserManager { if (userStats == null) { return "User " + userName + " not found"; } - return "History of user " + userName + ": " + User.userStatsToMatchHistory(userStats.getProto()) + " " + User.userStatsToTourneyHistory(userStats.getProto()); + return "History of user " + userName + ": " + User.userStatsToHistory(userStats.getProto()); } - return "History of user " + userName + ": " + user.getUserData().getMatchHistory() + " " + user.getUserData().getTourneyHistory(); + return "History of user " + userName + ": " + user.getUserData().getHistory(); } public void updateUserHistory() { diff --git a/Mage/src/main/java/mage/players/net/UserData.java b/Mage/src/main/java/mage/players/net/UserData.java index 949cbbd6d4..f875260d2c 100644 --- a/Mage/src/main/java/mage/players/net/UserData.java +++ b/Mage/src/main/java/mage/players/net/UserData.java @@ -171,6 +171,10 @@ public class UserData implements Serializable { this.autoOrderTrigger = autoOrderTrigger; } + public String getHistory() { + return "Matches:" + this.matchHistory + " Tourneys:" + this.tourneyHistory; + } + public void setMatchHistory(String history) { this.matchHistory = history; }