diff --git a/src/main/java/com/Acrobot/ChestShop/UUIDs/NameManager.java b/src/main/java/com/Acrobot/ChestShop/UUIDs/NameManager.java index 8cf0c4373..63dd3403e 100644 --- a/src/main/java/com/Acrobot/ChestShop/UUIDs/NameManager.java +++ b/src/main/java/com/Acrobot/ChestShop/UUIDs/NameManager.java @@ -44,14 +44,20 @@ public static UUID getUUIDForFullName(String name) { return fullNamesToUUID.get(name.toLowerCase()); } - public static UUID getUUIDFor(String shortName) { - if (ChestShopSign.isAdminshopLine(shortName)) { + public static UUID getUUIDFor(String name) { + if (ChestShopSign.isAdminshopLine(name)) { return adminShopUUID; } - if (Properties.SERVER_ECONOMY_ACCOUNT != null && Properties.SERVER_ECONOMY_ACCOUNT.length() > 0 && Properties.SERVER_ECONOMY_ACCOUNT.equals(shortName)) { + if (Properties.SERVER_ECONOMY_ACCOUNT != null && Properties.SERVER_ECONOMY_ACCOUNT.length() > 0 + && Properties.SERVER_ECONOMY_ACCOUNT.equals(name)) { return serverAccountUUID; } - return usedShortNames.get(shortName.toLowerCase()); + + UUID uuid = usedShortNames.get(name.toLowerCase()); + if (uuid != null) + return uuid; + + return getUUIDForFullName(name); } public static String getFullNameFor(UUID playerId) {