From cb69f84ed63d7d248253eede2ab19f79d3978619 Mon Sep 17 00:00:00 2001 From: Nicholas Ignoffo Date: Fri, 8 Feb 2019 20:21:59 -0800 Subject: [PATCH] Fix oredict filter passing invalid stacks to oredict (#1481) --- .../java/WayofTime/bloodmagic/routing/OreDictItemFilter.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main/java/WayofTime/bloodmagic/routing/OreDictItemFilter.java b/src/main/java/WayofTime/bloodmagic/routing/OreDictItemFilter.java index 812c4cc3..aa209492 100644 --- a/src/main/java/WayofTime/bloodmagic/routing/OreDictItemFilter.java +++ b/src/main/java/WayofTime/bloodmagic/routing/OreDictItemFilter.java @@ -17,6 +17,9 @@ public class OreDictItemFilter extends TestItemFilter { @Override public boolean doStacksMatch(ItemStack filterStack, ItemStack testStack) { + if (filterStack.isEmpty() || testStack.isEmpty()) + return false; + int[] filterIds = OreDictionary.getOreIDs(filterStack); int[] testIds = OreDictionary.getOreIDs(testStack);