From e022f1a948c381016caee00cc7d867e9656a8a09 Mon Sep 17 00:00:00 2001 From: Generation4 Date: Tue, 7 Jun 2022 13:35:06 +0300 Subject: [PATCH] Fixed tinymce5 changing image issue In TinyMCE 5, when tring to select new image to replace exist one the function usingTinymce4AndColorbox() returns TRUE (False Positive). The bug is preventing from changing the existing image. I fixed it with extra check to insure usingTinymce4AndColorbox() is returning FALSE when TinyMCE 5 is active. --- public/js/script.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/js/script.js b/public/js/script.js index 2a2b49c9..3eb715fd 100644 --- a/public/js/script.js +++ b/public/js/script.js @@ -760,7 +760,7 @@ function usingTinymce3() { } function usingTinymce4AndColorbox() { - return !!getUrlParam('field_name'); + return !!getUrlParam('field_name') && getUrlParam('editor') != 'tinymce5'; } function usingTinymce5(){