sort fixing