Skip to content

Commit 01a3743

Browse files
committed
Tighten JSON generation
1 parent 3c6b2dc commit 01a3743

File tree

2 files changed

+1
-4
lines changed

2 files changed

+1
-4
lines changed

convex-core/src/main/java/convex/core/util/JSONUtils.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -182,9 +182,7 @@ private static void appendJSON(BlobBuilder bb, Object value) {
182182
if (i>0) bb.append(",");
183183
appendJSON(bb, jsonKey(me.getKey()));
184184
bb.append(':');
185-
bb.append(' ');
186185
appendJSON(bb, me.getValue());
187-
188186
i += 1;
189187
}
190188

@@ -278,7 +276,6 @@ private static void appendJSON(BlobBuilder bb, ACell value) {
278276
MapEntry<?,?> me=mv.entryAt(i);
279277
appendJSON(bb, jsonKey(me.getKey()));
280278
bb.append(':');
281-
bb.append(' ');
282279
appendJSON(bb, me.getValue());
283280
}
284281
bb.append('}');

convex-java/src/main/java/convex/java/JSON.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ public static String toPrettyString(Object value) {
110110
* @throws RuntimeException on failure to create JSON from value
111111
*/
112112
public static String toString(Object value) {
113-
return JSONValue.toJSONString(value);
113+
return JSONUtils.toString(value);
114114
}
115115

116116
/**

0 commit comments

Comments
 (0)