fix implicit ordering error