modify the Collection sort methods to reset the keys when the array isn't associative