Skip to content

Commit

Permalink
Json.prettyPrint didn't do pretty
Browse files Browse the repository at this point in the history
  • Loading branch information
SlimerDude committed Jul 12, 2021
1 parent f11e97e commit 55fd133
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .project
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>Json</name>
<name>JSON</name>
<comment></comment>
<projects>
</projects>
Expand Down
1 change: 1 addition & 0 deletions doc/releaseNotes.fandoc
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ v2.0.12
- New: 'toJsonArray()' and 'fromJsonArray()' in 'JsonConverters'.
- New: Added 'escapeUnicode' option to 'JsonWriter' to disable Unicode escaping.
- Chg: 'JsonConverters.toJsonVal()' now has a default 'fantomType' param.
- Bug: 'Json.prettyPrint()' didn't do *pretty* unless 'true' was passed as an option.

v2.0.10
=======
Expand Down
2 changes: 1 addition & 1 deletion fan/Json.fan
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
if (fantomObj is Str)
fantomObj = JsonReader().readJson(fantomObj)

str := JsonWriter(options).writeJson(fantomObj)
str := JsonWriter(options ?: true).writeJson(fantomObj)
return str
}

Expand Down

0 comments on commit 55fd133

Please sign in to comment.