From a80161a31607e1c4b814b5e7e2897b00ebb2b83e Mon Sep 17 00:00:00 2001 From: the-djmaze <> Date: Mon, 29 Aug 2022 10:54:55 +0200 Subject: [PATCH] Bugfix: keep A elements when there is an image inside --- dev/Common/Html.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dev/Common/Html.js b/dev/Common/Html.js index b3d8c3aae..1d8254ca4 100644 --- a/dev/Common/Html.js +++ b/dev/Common/Html.js @@ -136,7 +136,7 @@ export const } // if (['CENTER','FORM'].includes(name)) { if ('FORM' === name || 'O:P' === name || (nonEmptyTags.includes(name) && ('' == oElement.textContent.trim()))) { - replaceWithChildren(oElement); + ('A' !== name || !oElement.querySelector('IMG')) && replaceWithChildren(oElement); return; } /*