From 377710b3c3c5966d7ed1099c58b7fc3b90d68efc Mon Sep 17 00:00:00 2001 From: j502647092 Date: Sun, 4 Oct 2015 20:37:36 +0800 Subject: [PATCH] fix message error... Signed-off-by: j502647092 --- src/main/java/org/maxgamer/QuickShop/Util/MsgUtil.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/java/org/maxgamer/QuickShop/Util/MsgUtil.java b/src/main/java/org/maxgamer/QuickShop/Util/MsgUtil.java index 2c41f32..6ea0aeb 100644 --- a/src/main/java/org/maxgamer/QuickShop/Util/MsgUtil.java +++ b/src/main/java/org/maxgamer/QuickShop/Util/MsgUtil.java @@ -26,7 +26,7 @@ import mkremins.fanciful.FancyMessage; public class MsgUtil { private static QuickShop plugin; private static YamlConfiguration messages; - private static HashMap> player_messages = new HashMap>(); + private static HashMap> player_messages = new HashMap>(); static { plugin = QuickShop.instance; @@ -84,7 +84,7 @@ public class MsgUtil { try { final ResultSet rs = plugin.getDB().getConnection().prepareStatement("SELECT * FROM messages").executeQuery(); while (rs.next()) { - final String owner = rs.getString("owner"); + final UUID owner = UUID.fromString(rs.getString("owner")); final String message = rs.getString("message"); LinkedList msgs = player_messages.get(owner); if (msgs == null) { @@ -121,7 +121,7 @@ public class MsgUtil { * they're online. Else, if they're not online, queues it for * them in the database. */ - public static void send(final String player, final String message) { // TODO Converted to UUID + public static void send(final UUID player, final String message) { // TODO Converted to UUID final OfflinePlayer p = Bukkit.getOfflinePlayer(player); if (p == null || !p.isOnline()) { LinkedList msgs = player_messages.get(player);