From: Alexander Ebert Date: Fri, 3 Jul 2015 10:57:40 +0000 (+0200) Subject: Prevent empty anchor being spawned when editing an image X-Git-Tag: 2.1.6~19 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=9873b92fde5d685588213b8b81fe1543abc2b978;p=GitHub%2FWoltLab%2FWCF.git Prevent empty anchor being spawned when editing an image --- diff --git a/wcfsetup/install/files/js/3rdParty/redactor/plugins/wmonkeypatch.js b/wcfsetup/install/files/js/3rdParty/redactor/plugins/wmonkeypatch.js index 9cf41559cf..b34c14fc09 100644 --- a/wcfsetup/install/files/js/3rdParty/redactor/plugins/wmonkeypatch.js +++ b/wcfsetup/install/files/js/3rdParty/redactor/plugins/wmonkeypatch.js @@ -658,7 +658,7 @@ RedactorPlugins.wmonkeypatch = function() { anchor.attr('href', link); } } - else { + else if (link !== '') { anchor = document.createElement('a'); anchor.href = link; image[0].parentNode.insertBefore(anchor, image[0]);