revise sort