Fix last change in json.el
* lisp/json.el (json-encode-array): Include optimization for lists.
This commit is contained in:
parent
dbc16cdd13
commit
9c0387d786
1 changed files with 3 additions and 1 deletions
|
@ -654,7 +654,9 @@ become JSON objects."
|
|||
(defun json-encode-array (array)
|
||||
"Return a JSON representation of ARRAY."
|
||||
(if (and json-encoding-pretty-print
|
||||
(/= 0 (length array)))
|
||||
(if (listp array)
|
||||
array
|
||||
(> (length array) 0)))
|
||||
(concat
|
||||
"["
|
||||
(json--with-indentation
|
||||
|
|
Loading…
Add table
Reference in a new issue