1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-30 21:40:43 +02:00

[ticket/13901] Add whitespace to short, multiline quotes for readability

PHPBB3-13901
This commit is contained in:
JoshyPHP
2015-05-30 22:20:52 +02:00
parent 2f0d11ba3c
commit b69e33c2b0
2 changed files with 6 additions and 1 deletions

View File

@@ -69,7 +69,7 @@ class utils implements \phpbb\textformatter\utils_interface
$quote .= ' ' . $name . '=' . $this->enquote($value);
}
$quote .= ']';
$newline = (strlen($quote . $text . '[/quote]') > 80) ? "\n" : '';
$newline = (strlen($quote . $text . '[/quote]') > 80 || strpos($text, "\n") !== false) ? "\n" : '';
$quote .= $newline . $text . $newline . '[/quote]';
return $quote;