r87922 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r87921‎ | r87922 | r87923 >
Date:19:06, 12 May 2011
Author:ialex
Status:deferred
Tags:
Comment:
OutputPage::addWikiText() with wfMsg() -> OutputPage::addWikiMsg()
Modified paths:
  • /trunk/extensions/Commentbox/SpecialAddComment_body.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Commentbox/SpecialAddComment_body.php
@@ -60,8 +60,8 @@
6161 $wgOut->setRobotPolicy( 'noindex,nofollow' );
6262 $wgOut->setArticleRelated( false );
6363
64 - $wgOut->addWikiText( wfMsg( 'spamprotectiontext' ) );
65 - $wgOut->addWikiText( wfMsg( 'spamprotectionmatch', "<nowiki>{$matches[0]}</nowiki>" ) );
 64+ $wgOut->addWikiMsg( 'spamprotectiontext' );
 65+ $wgOut->addWikiMsg( 'spamprotectionmatch', "<nowiki>{$matches[0]}</nowiki>" );
6666 $wgOut->returnToMain( false, $title );
6767 return;
6868 }
@@ -111,7 +111,7 @@
112112 function fail( $str, $title = null ) {
113113 global $wgOut;
114114 $wgOut->setPageTitle( wfMsg( 'commentbox-errorpage-title' ) );
115 - $wgOut->addWikiText( "<div class='errorbox'>" . wfMsg( $str ) . "</div><br clear='both' />" );
 115+ $wgOut->wrapWikiMsg( "<div class='errorbox'>$1</div><br clear='both' />", $str );
116116 if ( $title != null )
117117 $wgOut->returnToMain( false, $title );
118118 return;

Status & tagging log