r86732 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r86731‎ | r86732 | r86733 >
Date:19:52, 22 April 2011
Author:ialex
Status:deferred (Comments)
Tags:
Comment:
Changed last two calls to wfMsgNoDB() to wfMessage() and marked it as deprecated
Modified paths:
  • /trunk/extensions/Farmer/MediaWikiFarmer_Wiki.php (modified) (history)
  • /trunk/extensions/Farmer/SpecialFarmer.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Farmer/SpecialFarmer.php
@@ -130,7 +130,7 @@
131131 $log->addEntry( 'create', $this->getTitle(), $reason, array( $name ) );
132132
133133 $wgOut->wrapWikiMsg( '== $1 ==', 'farmer-wikicreated' );
134 - $wgOut->addWikiMsg( 'farmer-wikicreated-text', $wikiObj->getUrl( wfUrlencode( wfMsgNoDB( 'mainpage' ) ) ) );
 134+ $wgOut->addWikiMsg( 'farmer-wikicreated-text', $wikiObj->getUrl( wfUrlencode( wfMessage( 'mainpage' )->inContentLanguage()->useDatabase( false )->plain() ) ) );
135135 $wgOut->addWikiMsg( 'farmer-default', '[[' . $title . ':Special:Farmer|Special:Farmer]]' );
136136 return;
137137 }
Index: trunk/extensions/Farmer/MediaWikiFarmer_Wiki.php
@@ -464,7 +464,7 @@
465465 protected function _createMainPageForWiki() {
466466 $db = $this->getDatabase();
467467
468 - $titleobj = Title::newFromText( wfMsgNoDB( 'mainpage' ) );
 468+ $titleobj = Title::newFromText( wfMessage( 'mainpage' )->inContentLanguage()->useDatabase( false )->plain() );
469469 $article = new Article( $titleobj );
470470 $newid = $article->insertOn( $db );
471471 $revision = new Revision( array(

Follow-up revisions

RevisionCommit summaryAuthorDate
r86733Follow-up r86732: really mark it as deprecated ;)ialex19:54, 22 April 2011

Comments

#Comment by Nikerabbit (talk | contribs)   19:56, 22 April 2011

Yet another unmaintained extension full of bugs? :) I see at least three in this short context.

Status & tagging log