Skip to content

Commit d423715

Browse files
authored
Fix: Uncaught error on CKE cleanup (fixes #2801) (#2802)
2 parents 9163f38 + ead7fdc commit d423715

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)