fix double spaces in pair_sort