Fix last <br/> removal cutting off text when rendering a text block [MAILPOET-856]

This commit is contained in:
Alexey Stoletniy
2017-04-06 10:07:11 +03:00
parent 66d969cc2f
commit 37fcd5699b
3 changed files with 13 additions and 1 deletions

View File

@@ -166,7 +166,7 @@ class Text {
}
static function removeLastLineBreak($html) {
return preg_replace('/(^)?(<br.*?\/?>)+$/i', '', $html);
return preg_replace('/(^)?(<br[^>]*?\/?>)+$/i', '', $html);
}
static function insertLineBreak($element) {