aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Christian Hesse <mail@eworm.de>2023-10-16 23:39:27 +0200
committerGravatar Christian Hesse <mail@eworm.de>2023-10-16 23:43:58 +0200
commit3b9df48721c6cb6c3018581749cdbcb6442774a5 (patch)
tree0e08bd1abeb34a05b3ca09d3cc2633f861ec263a
parent140ec1a3a26af52572e755c126323097e56a4faa (diff)
global-functions: $ParseJson: prepare elif-workaround
-rw-r--r--global-functions.rsc5
1 files changed, 4 insertions, 1 deletions
diff --git a/global-functions.rsc b/global-functions.rsc
index d510ff9..8dc8c02 100644
--- a/global-functions.rsc
+++ b/global-functions.rsc
@@ -714,13 +714,16 @@
:set $Skip ($Skip - 1);
}
} else={
+ :local Done false;
:local Key ($Input->$I);
:local Val1 ($Input->($I + 1));
:local Val2 ($Input->($I + 2));
:if ($Val1 = ":") do={
:set ($Return->$Key) $Val2;
:set Skip 2;
- } else={
+ :set Done true;
+ }
+ :if ($Done = false) do={
:set ($Return->$Key) [ :pick $Val1 1 [ :len $Val1 ] ];
:set Skip 1;
}