sorted incorrect second time