From: Alexander Ebert Date: Wed, 21 Jan 2015 00:23:54 +0000 (+0100) Subject: Unified behavior for newline after [/quote] tag X-Git-Tag: 2.1.0_Beta_4~64^2~2 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=7263f9805e10a664778c1868de0df58b8d749ffc;p=GitHub%2FWoltLab%2FWCF.git Unified behavior for newline after [/quote] tag --- diff --git a/wcfsetup/install/files/js/3rdParty/redactor/plugins/wutil.js b/wcfsetup/install/files/js/3rdParty/redactor/plugins/wutil.js index 1aa841b9ac..a4cee4264a 100644 --- a/wcfsetup/install/files/js/3rdParty/redactor/plugins/wutil.js +++ b/wcfsetup/install/files/js/3rdParty/redactor/plugins/wutil.js @@ -256,7 +256,13 @@ RedactorPlugins.wutil = function() { submit: function() { if (this.wutil.inWysiwygMode()) { this.code.startSync(); - this.$textarea.val($.trim(this.wbbcode.convertFromHtml(this.$textarea.val()))); + + var $text = $.trim(this.wbbcode.convertFromHtml(this.$textarea.val())); + + // remove linebreak after [/quote] + $text = $text.replace(/\[\/quote\]\n/g, '[/quote]'); + + this.$textarea.val($text); } this.wutil.autosavePurge();