summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Adam Chlipala <adam@chlipala.net>2019-12-19 11:58:13 -0500
committerGravatar Adam Chlipala <adam@chlipala.net>2019-12-19 11:58:13 -0500
commit383e3a559b65432e9e2357dc35670ce147be96da (patch)
tree97ddc866a7ca97f3c0e5a730a4a6006ab983b0d5
parentf48703bf1b39c94c941ba101c3d2fd56a78d8289 (diff)
Fix toJson for records with optional fields
-rw-r--r--lib/ur/json.ur2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ur/json.ur b/lib/ur/json.ur
index 58822d4b..eed52fd6 100644
--- a/lib/ur/json.ur
+++ b/lib/ur/json.ur
@@ -356,7 +356,7 @@ fun json_record_withOptional [ts ::: {Type}] [ots ::: {Type}] [ts ~ ots]
escape name ^ ":" ^ j.ToJson v ^ (case acc of
"" => ""
| acc => "," ^ acc))
- "" ofl ojss onames (r --- _)
+ withRequired ofl ojss onames (r --- _)
in
"{" ^ withOptional ^ "}"
end,