Fix ownership leak in ItemStackHandler (#6580)

- Triggered by invoking ItemStackHandler#extractItem with `simulate=true`
This commit is contained in:
hnOsmium0001 authored and GitHub committed 2020-03-27 16:10:21 -07:00
1 parent dd1d8737ad
commit fcee09cab2
1 file changed
+5 -1
@@ -141,8 +141,12 @@ public class ItemStackHandler implements IItemHandler, IItemHandlerModifiable, I
{
this.stacks.set(slot, ItemStack.EMPTY);
onContentsChanged(slot);
return existing;
}
else
{
return existing.copy();
}
return existing;
}
else
{