[FIX] Crash when trying to sort keys.