From: Coleman Watts Date: Tue, 27 Oct 2015 19:12:26 +0000 (-0400) Subject: CRM-16354 - Add sanity check X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=5f005e5d7fa9d40e690c19da008a6f759a313d80;p=civicrm-core.git CRM-16354 - Add sanity check --- diff --git a/js/wysiwyg/crm.ckeditor.js b/js/wysiwyg/crm.ckeditor.js index b856dee028..853252e88c 100644 --- a/js/wysiwyg/crm.ckeditor.js +++ b/js/wysiwyg/crm.ckeditor.js @@ -5,10 +5,10 @@ function getInstance(item) { var name = $(item).attr("name"), id = $(item).attr("id"); - if (name && CKEDITOR.instances[name]) { + if (name && window.CKEDITOR && CKEDITOR.instances[name]) { return CKEDITOR.instances[name]; } - if (id && CKEDITOR.instances[id]) { + if (id && window.CKEDITOR && CKEDITOR.instances[id]) { return CKEDITOR.instances[id]; } }