Merge pull request #256 from MiroHibler/develop

Error if 'search' option set to false
This commit is contained in:
Jos de Jong 2016-01-15 20:43:52 +01:00
commit 178610a76c
3 changed files with 10 additions and 3 deletions

View File

@ -3,6 +3,11 @@
https://github.com/josdejong/jsoneditor
## not yet released, version 5.1.1
- Fixed #255: Removed wrong console warning about the option `search`.
## 2016-01-14, version 5.1.0
- Implemented support for JSON schema validation, powered by `ajv`.

View File

@ -77,7 +77,7 @@ function JSONEditor (container, options, json) {
'ace', 'theme',
'ajv', 'schema',
'onChange', 'onEditable', 'onError', 'onModeChange',
'escapeUnicode', 'history', 'mode', 'modes', 'name', 'indentation'
'escapeUnicode', 'history', 'search', 'mode', 'modes', 'name', 'indentation'
];
Object.keys(options).forEach(function (option) {

View File

@ -145,7 +145,9 @@ treemode.set = function (json, name) {
}
// clear search
this.searchBox.clear();
if (this.searchBox) {
this.searchBox.clear();
}
};
/**