File tree Expand file tree Collapse file tree 2 files changed +2
-1
lines changed
Expand file tree Collapse file tree 2 files changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -36,7 +36,7 @@ func fromObject(obj Object) interface{} {
3636 return res
3737 case Seqable :
3838 s := obj .Seq ()
39- var res []interface {}
39+ var res []interface {} = [] interface {}{}
4040 for ! s .IsEmpty () {
4141 res = append (res , fromObject (s .First ()))
4242 s = s .Rest ()
Original file line number Diff line number Diff line change 1212 (is (= "\"keyword\"" (json/write-string :keyword)))
1313 (is (= "null" (json/write-string nil)))
1414 (is (= "\"string\"" (json/write-string "string")))
15+ (is (= "[]" (json/write-string [])))
1516 (is (= "{\"keyword\":\"string\"}" (json/write-string {:keyword "string"})))
1617 (is (= "[1,true]" (json/write-string [1 true])))
1718 (is (= "[\"string\",null]" (json/write-string (drop 2 [1 true "string" nil]))))
You can’t perform that action at this time.
0 commit comments