add fix_order function with minimal documentation and no demo