Handle quantity auto indexing. Clean-up