[OE-5210] Fix sorting