fix problem with Extended, ksort now using sort function equal to SortKey