Browse Source

Improve walk_json().

pull/24/head
Ben Kurtovic 9 years ago
parent
commit
8a2f1f022e
1 changed files with 4 additions and 2 deletions
  1. +4
    -2
      templates/api.mako

+ 4
- 2
templates/api.mako View File

@@ -13,7 +13,7 @@
% endfor
${do_indent(indent)}
}
% elif isinstance(obj, type([])):
% elif isinstance(obj, (type([]), type(()))):
[
% for member in obj:
${do_indent(indent + 1)}
@@ -21,8 +21,10 @@
% endfor
${do_indent(indent)}
]
% elif isinstance(obj, type("").__bases__[0]):
"${obj | h}"
% else:
${repr(obj) | h}
${obj | h}
% endif
</%def>\
<!DOCTYPE html>


Loading…
Cancel
Save