Match class exactly for flower bag inventory

This commit is contained in:
Vincent Lee committed 2019-12-30 16:49:06 -06:00
1 parent 74c1bb464f
commit 2c6f3f8f22
1 file changed
+1 -1
@@ -68,7 +68,7 @@ public class ItemFlowerBag extends ItemMod {
public boolean isItemValid(int slot, @Nonnull ItemStack stack) {
Block blk = Block.getBlockFromItem(stack.getItem());
return !stack.isEmpty()
&& blk instanceof BlockModFlower
&& blk.getClass() == BlockModFlower.class
&& slot == ((BlockModFlower) blk).color.getId();
}
};