From 2d5ab5780e83063e387955f8a8e940119c0a1a5c Mon Sep 17 00:00:00 2001 From: Chip Morningstar Date: Fri, 7 Jan 2022 13:06:59 -0800 Subject: [PATCH] fix: update sort order so undefined comes last --- packages/store/src/patterns/rankOrder.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/store/src/patterns/rankOrder.js b/packages/store/src/patterns/rankOrder.js index c1629878f47..12e94479299 100644 --- a/packages/store/src/patterns/rankOrder.js +++ b/packages/store/src/patterns/rankOrder.js @@ -26,9 +26,9 @@ const PassStyleRankAndCover = harden([ /* np */ ['bigint', ['n', 'p~']], /* r */ ['remotable', ['r', 'r~']], /* s */ ['string', ['s', 't']], - /* u */ ['undefined', ['u', 'v']], + /* v */ ['null', ['v', 'v~']], /* y */ ['symbol', ['y', 'z']], - /* z */ ['null', ['z', 'z~']], + /* z */ ['undefined', ['z', '{']], /* | remotable->ordinal mapping prefix: This is not used in covers but it is reserved from the same set of strings. Note that the prefix is > any prefix used by any cover so that ordinal mapping keys are always outside