From f3581e974fb6adf02abe4fdd1480e57d13271338 Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Fri, 20 Jan 2017 11:08:55 +0100 Subject: [PATCH] Fixed paste handling --- .../files/js/3rdParty/redactor2/plugins/WoltLabPaste.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/wcfsetup/install/files/js/3rdParty/redactor2/plugins/WoltLabPaste.js b/wcfsetup/install/files/js/3rdParty/redactor2/plugins/WoltLabPaste.js index 3117a675c1..2038df8e0b 100644 --- a/wcfsetup/install/files/js/3rdParty/redactor2/plugins/WoltLabPaste.js +++ b/wcfsetup/install/files/js/3rdParty/redactor2/plugins/WoltLabPaste.js @@ -125,10 +125,7 @@ $.Redactor.prototype.WoltLabPaste = function() { this.paste.insert = (function(html, data) { if (isKbd) data.pre = true; - if (data.pre) { - return mpInsert.call(this, html, data); - } - else if (this.utils.isCurrentOrParent('kbd')) { + if (this.utils.isCurrentOrParent('kbd')) { mpInsert.call(this, html, data); var current = this.selection.current(); @@ -159,6 +156,9 @@ $.Redactor.prototype.WoltLabPaste = function() { return; } + else if (data.pre) { + return mpInsert.call(this, html, data); + } var div = elCreate('div'); div.innerHTML = html; -- 2.20.1