diff --git a/src/main/java/com/Acrobot/ChestShop/Listeners/ShopRemoval/ShopRefundListener.java b/src/main/java/com/Acrobot/ChestShop/Listeners/ShopRemoval/ShopRefundListener.java index bbb0b3f..219583c 100644 --- a/src/main/java/com/Acrobot/ChestShop/Listeners/ShopRemoval/ShopRefundListener.java +++ b/src/main/java/com/Acrobot/ChestShop/Listeners/ShopRemoval/ShopRefundListener.java @@ -30,7 +30,8 @@ public class ShopRefundListener implements Listener { return; } - UUID owner = NameManager.getUUID(event.getSign().getLine(NAME_LINE)); + String ownerName = NameManager.getFullUsername(event.getSign().getLine(NAME_LINE)); + UUID owner = NameManager.getUUID(ownerName); CurrencyAddEvent currencyEvent = new CurrencyAddEvent(BigDecimal.valueOf(refundPrice), owner, event.getSign().getWorld()); ChestShop.callEvent(currencyEvent); diff --git a/src/main/java/com/Acrobot/ChestShop/UUIDs/NameManager.java b/src/main/java/com/Acrobot/ChestShop/UUIDs/NameManager.java index a58f300..fdffb30 100644 --- a/src/main/java/com/Acrobot/ChestShop/UUIDs/NameManager.java +++ b/src/main/java/com/Acrobot/ChestShop/UUIDs/NameManager.java @@ -59,7 +59,7 @@ public class NameManager { UUID uuid = account.getUuid(); if (uuid != null) { - usernameToUUID.put(username, uuid); + usernameToUUID.put(account.getName(), uuid); } return uuid;