Fix sort order checking to not always return NONE

Merge request reports