Problem with sorting collection when many images are present