From: aude Date: Fri, 26 Oct 2012 04:10:19 +0000 (+0000) Subject: (bug 41298) re-apply I9a56b7c6, Don't parse the section's name in the summary X-Git-Tag: 1.31.0-rc.0~21853 X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/comptes/ajouter.php?a=commitdiff_plain;h=eaca7a01cfe6000ed0cc75241da1428853cdc05d;p=lhc%2Fweb%2Fwiklou.git (bug 41298) re-apply I9a56b7c6, Don't parse the section's name in the summary Change-Id: I11492200ed8cd199dbbde737a28e8acb07403096 --- diff --git a/includes/EditPage.php b/includes/EditPage.php index 64167d785a..67f0b4670b 100644 --- a/includes/EditPage.php +++ b/includes/EditPage.php @@ -1398,8 +1398,8 @@ class EditPage { // passed. if ( $this->summary === '' ) { $cleanSectionTitle = $wgParser->stripSectionName( $this->sectiontitle ); - $this->summary = wfMessage( 'newsectionsummary', $cleanSectionTitle ) - ->inContentLanguage()->text() ; + $this->summary = wfMessage( 'newsectionsummary' ) + ->rawParams( $cleanSectionTitle )->inContentLanguage()->text(); } } elseif ( $this->summary !== '' ) { // Insert the section title above the content. @@ -1410,8 +1410,8 @@ class EditPage { // Create a link to the new section from the edit summary. $cleanSummary = $wgParser->stripSectionName( $this->summary ); - $this->summary = wfMessage( 'newsectionsummary', $cleanSummary ) - ->inContentLanguage()->text(); + $this->summary = wfMessage( 'newsectionsummary' ) + ->rawParams( $cleanSummary )->inContentLanguage()->text(); } } @@ -1555,16 +1555,16 @@ class EditPage { // passed. if ( $this->summary === '' ) { $cleanSectionTitle = $wgParser->stripSectionName( $this->sectiontitle ); - $this->summary = wfMessage( 'newsectionsummary', $cleanSectionTitle ) - ->inContentLanguage()->text(); + $this->summary = wfMessage( 'newsectionsummary' ) + ->rawParams( $cleanSectionTitle )->inContentLanguage()->text(); } } elseif ( $this->summary !== '' ) { $sectionanchor = $wgParser->guessLegacySectionNameFromWikiText( $this->summary ); # This is a new section, so create a link to the new section # in the revision summary. $cleanSummary = $wgParser->stripSectionName( $this->summary ); - $this->summary = wfMessage( 'newsectionsummary', $cleanSummary ) - ->inContentLanguage()->text(); + $this->summary = wfMessage( 'newsectionsummary' ) + ->rawParams( $cleanSummary )->inContentLanguage()->text(); } } elseif ( $this->section != '' ) { # Try to get a section anchor from the section source, redirect to edited section if header found