Add checks for if an ItemStack has a null item. This isn't a full fix,
but should catch 90% or close to it of the isses for bug #1414