From 1da2b9eecbef645beffaf06e58225b2854d2a31e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20B=C3=B6hmer?= Date: Mon, 15 Jan 2024 20:39:27 +0100 Subject: [PATCH] Fixed javascript error caused by CKEDITOR This was not really a problem, just annoying. But now it is fixed. Fixes issue #457 --- assets/controllers/elements/ckeditor_controller.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/assets/controllers/elements/ckeditor_controller.js b/assets/controllers/elements/ckeditor_controller.js index 4de536fe..f368324f 100644 --- a/assets/controllers/elements/ckeditor_controller.js +++ b/assets/controllers/elements/ckeditor_controller.js @@ -70,7 +70,9 @@ export default class extends Controller { editor_div.classList.add(...new_classes.split(",")); } - console.log(editor); + //This return is important! Otherwise we get mysterious errors in the console + //See: https://github.com/ckeditor/ckeditor5/issues/5897#issuecomment-628471302 + return editor; }) .catch(error => { console.error(error);