From 7fce67144dd1b610d4c250939f194b04b0f64a9e Mon Sep 17 00:00:00 2001 From: md_5 Date: Wed, 8 Mar 2017 14:33:40 +1100 Subject: [PATCH] SPIGOT-3108: Hack around mirroring empty item stacks --- .../java/org/bukkit/craftbukkit/inventory/CraftItemStack.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java index 6adbbd4acc..a54bc7c423 100644 --- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java +++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java @@ -71,7 +71,7 @@ public final class CraftItemStack extends ItemStack { } public static CraftItemStack asCraftMirror(net.minecraft.server.ItemStack original) { - return new CraftItemStack(original); + return new CraftItemStack((original == null || original.isEmpty()) ? null : original); } public static CraftItemStack asCraftCopy(ItemStack original) {