Skip to content

Commit b937aac

Browse files
committed
fix: fix JSON editor parsing
1 parent 55369cd commit b937aac

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

ckanext/resource_docs/assets/js/rdocs-jsoneditor-docs.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,8 +130,8 @@ ckan.module("rdocs-jsoneditor-docs", function ($, _) {
130130
_overrideResourceDocs: function () {
131131
let content = window.JSONEditorDOCS.get();
132132

133-
if (!content.text) {
134-
content = {text: {}}
133+
if (!content.text && !content.json) {
134+
content = {json: {}}
135135
}
136136

137137
const docs = toJSONContent(content);

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "ckanext-resource-docs"
3-
version = "0.4.1"
3+
version = "0.4.2"
44
description = "A CKAN extension that lets you attach a flexible, schema-free data dictionary (“resource documentation”) to any resource, not just Datastore-backed ones."
55
readme = "README.md"
66
authors = [{ name = "Oleksandr Cherniavskiy", email = "[email protected]" }]

0 commit comments

Comments
 (0)