From e87cfc9a6b29f6b55bc1365cd386dbd9dcd31694 Mon Sep 17 00:00:00 2001 From: j502647092 Date: Mon, 5 Oct 2015 04:33:38 +0800 Subject: [PATCH] remove err tip... Signed-off-by: j502647092 --- .../java/org/maxgamer/QuickShop/Shop/ContainerShop.java | 3 ++- src/main/java/org/maxgamer/QuickShop/Shop/DisplayItem.java | 6 +----- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/src/main/java/org/maxgamer/QuickShop/Shop/ContainerShop.java b/src/main/java/org/maxgamer/QuickShop/Shop/ContainerShop.java index a9e8955..bf3e3ef 100644 --- a/src/main/java/org/maxgamer/QuickShop/Shop/ContainerShop.java +++ b/src/main/java/org/maxgamer/QuickShop/Shop/ContainerShop.java @@ -662,8 +662,9 @@ public class ContainerShop implements Shop { try { plugin.getDB().execute(q, this.getOwner(), Util.serialize(this.getItem()), unlimited, shopType.toID(), this.getPrice(), x, y, z, world); } catch (final Exception e) { + plugin.getLogger().warning("无法保存商店到数据库!!!"); + plugin.getLogger().warning("错误信息: " + e.getMessage()); e.printStackTrace(); - System.out.println("Could not update shop in database! Changes will revert after a reboot!"); } } diff --git a/src/main/java/org/maxgamer/QuickShop/Shop/DisplayItem.java b/src/main/java/org/maxgamer/QuickShop/Shop/DisplayItem.java index b6b5a9a..08831b2 100644 --- a/src/main/java/org/maxgamer/QuickShop/Shop/DisplayItem.java +++ b/src/main/java/org/maxgamer/QuickShop/Shop/DisplayItem.java @@ -113,15 +113,11 @@ public class DisplayItem { try { this.item = shop.getLocation().getWorld().dropItem(dispLoc, this.iStack); this.item.setVelocity(new Vector(0, 0.1, 0)); + NMS.safeGuard(this.item); } catch (final Exception e) { } if (QuickShop.debug) { System.out.println("Spawned item. Safeguarding."); } - try { - NMS.safeGuard(this.item); - } catch (final Exception e) { - System.out.println("QuickShop version mismatch! This version of QuickShop is incompatible with this version of bukkit! Try update?"); - } } } \ No newline at end of file