diff --git a/main/src/main/java/me/blackvein/quests/listeners/PlayerListener.java b/main/src/main/java/me/blackvein/quests/listeners/PlayerListener.java index a52ced2bd..ab13245d6 100644 --- a/main/src/main/java/me/blackvein/quests/listeners/PlayerListener.java +++ b/main/src/main/java/me/blackvein/quests/listeners/PlayerListener.java @@ -94,12 +94,12 @@ public class PlayerListener implements Listener { evt.setCancelled(true); return; } - } else if (ac.equals(InventoryAction.SWAP_WITH_CURSOR))) { - ItemStack item=evt.getWhoClicked().getInventory().getItem(event.getHotbarButton()); - if (item!=null) { + } else if (ac.equals(InventoryAction.SWAP_WITH_CURSOR)) { + final ItemStack item = evt.getWhoClicked().getInventory().getItem(evt.getHotbarButton()); + if (item != null) { if (ItemUtil.isItem(item) && ItemUtil.isJournal(item)) { evt.setCancelled(true); - return; + return; } } }