Skip to content

Commit ead7fdc

Browse files
authored
Fix uncaught error on CKE cleanup
1 parent 9163f38 commit ead7fdc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

frontend/src/core/views/originView.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,10 +84,10 @@ define(function(require){
8484
if (this.form) {
8585
// remove ckeditor instances
8686
this.form.$( "textarea" ).each(function () {
87-
var editor = CKEDITOR.instances[this.id];
8887
try {
88+
var editor = CKEDITOR.instances[this.id];
8989
// check editor is still in the dom (otherwise throws exception)
90-
if (editor && editor.window.getFrame()) {
90+
if (editor.window.getFrame()) {
9191
editor.destroy(true);
9292
}
9393
} catch (e) {

0 commit comments

Comments
 (0)