Fixed ArrayIndexOutOfBoundsException and changed to using the Name instead of Itemstack