DOC: fix to_json docstring nesting issue