mostly fix, except for moving item to first slot of array