From b2f82f0f7f2e3d62a9f5511d0e19974ea9410dfd Mon Sep 17 00:00:00 2001 From: md_5 Date: Fri, 18 Nov 2016 09:14:51 +1100 Subject: [PATCH] Remove now redundant code --- .../java/org/bukkit/craftbukkit/event/CraftEventFactory.java | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java index 1c67ee9f57..b84b376a32 100644 --- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java +++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java @@ -220,10 +220,6 @@ public class CraftEventFactory { } BlockFace blockFace = CraftBlock.notchToBlockFace(direction); - if (itemInHand.getType() == Material.AIR || itemInHand.getAmount() == 0) { - itemInHand = null; - } - PlayerInteractEvent event = new PlayerInteractEvent(player, action, itemInHand, blockClicked, blockFace, (hand == null) ? null : ((hand == EnumHand.OFF_HAND) ? EquipmentSlot.OFF_HAND : EquipmentSlot.HAND)); if (cancelledBlock) { event.setUseInteractedBlock(Event.Result.DENY);