r46684 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r46683‎ | r46684 | r46685 >
Date:18:58, 1 February 2009
Author:siebrand
Status:deferred
Tags:
Comment:
(bug 14938) Removing a section no longer leaves excess whitespace. Contributed by Michael Walsh.
Modified paths:
  • /trunk/phase3/CREDITS (modified) (history)
  • /trunk/phase3/RELEASE-NOTES (modified) (history)
  • /trunk/phase3/includes/parser/Parser.php (modified) (history)

Diff [purge]

Index: trunk/phase3/CREDITS
@@ -70,6 +70,7 @@
7171 * Marooned
7272 * Max Semenik
7373 * Michael De La Rue
 74+* Michael Walsh
7475 * Mike Horvath
7576 * Mormegil
7677 * Nakon
Index: trunk/phase3/includes/parser/Parser.php
@@ -4543,7 +4543,11 @@
45444544 // Output the replacement text
45454545 // Add two newlines on -- trailing whitespace in $newText is conventionally
45464546 // stripped by the editor, so we need both newlines to restore the paragraph gap
4547 - $outText .= $newText . "\n\n";
 4547+ // Only add trailing whitespace if there is newText
 4548+ if($newText != "") {
 4549+ $outText .= $newText . "\n\n";
 4550+ }
 4551+
45484552 while ( $node ) {
45494553 $outText .= $frame->expand( $node, PPFrame::RECOVER_ORIG );
45504554 $node = $node->getNextSibling();
Index: trunk/phase3/RELEASE-NOTES
@@ -127,6 +127,7 @@
128128 * (bug 17146) Fix for UTF-8 and short word search for some possible MySQL configs
129129 * (bug 7480) Internationalize database error message
130130 * (bug 16555) Number of links to mediawiki.org scaled back on post-installation
 131+* (bug 14938) Removing a section no longer leaves excess whitespace
131132
132133 == API changes in 1.15 ==
133134 * (bug 16858) Revamped list=deletedrevs to make listing deleted contributions

Status & tagging log