diff --git a/Plan/src/main/java/com/djrapitops/plan/utilities/html/structure/ServerAccordionCreator.java b/Plan/src/main/java/com/djrapitops/plan/utilities/html/structure/ServerAccordionCreator.java index 613a54f31..ee14d1172 100644 --- a/Plan/src/main/java/com/djrapitops/plan/utilities/html/structure/ServerAccordionCreator.java +++ b/Plan/src/main/java/com/djrapitops/plan/utilities/html/structure/ServerAccordionCreator.java @@ -40,8 +40,7 @@ public class ServerAccordionCreator { for (Map.Entry entry : worldTimesPerServer.entrySet()) { UUID serverUUID = entry.getKey(); - String serverName = new Format(serverNames.getOrDefault(serverUUID, "Unknown")) - .removeSymbols().removeWhitespace().toString(); + String serverName = serverNames.getOrDefault(serverUUID, "Unknown"); WorldTimes worldTimes = entry.getValue(); List sessions = profile.getSessions(serverUUID); @@ -60,10 +59,11 @@ public class ServerAccordionCreator { String median = sessionCount != 0 ? FormatUtils.formatTimeAmount(sessionMedian) : "-"; String longest = sessionCount != 0 ? FormatUtils.formatTimeAmount(longestSession) : "-"; - String serverNameID = serverName.replace(" ", "_"); - String htmlID = "server_" + serverNameID; + String sanitizedServerName = new Format(serverName) + .removeSymbols().removeWhitespace().toString(); + String htmlID = "server_" + sanitizedServerName; - String worldId = "worldPieServer" + serverNameID; + String worldId = "worldPieServer" + sanitizedServerName; AnalysisUtils.addMissingWorlds(worldTimes); String[] worldData = WorldPieCreator.createSeriesData(worldTimes);