fix save on non-codemirror-editor-pages
This commit is contained in:
parent
1ac0fc0008
commit
c44dba20f1
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -211,7 +211,7 @@ $(document).on('ready pjax:success', function() {
|
|||
$('.CodeMirror').fadeIn();
|
||||
|
||||
// Save editor values
|
||||
if (typeof editor !== 'undefined') {
|
||||
if (typeof editor !== 'undefined' && editor) {
|
||||
editor.save();
|
||||
}
|
||||
|
||||
|
@ -252,7 +252,6 @@ $(document).on('ready pjax:success', function() {
|
|||
event.preventDefault();
|
||||
|
||||
if ($("#new-admin-item-123").length) {
|
||||
console.log("oi")
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue