From: Fomafix Date: Mon, 9 Nov 2015 05:28:58 +0000 (+0000) Subject: Replace Language::factory( $wgLanguageCode ) by $wgContLang X-Git-Tag: 1.31.0-rc.0~9057 X-Git-Url: https://git.cyclocoop.org/%27.%24link.%27?a=commitdiff_plain;h=9deadb74526aa2d8a9e53f6b0dfc843382ead290;p=lhc%2Fweb%2Fwiklou.git Replace Language::factory( $wgLanguageCode ) by $wgContLang $wgContLang is filled with Language::factory( $wgLanguageCode ) in Setup.php Change-Id: I2cb222ee793106140755cf109f9fcc5fcbaa4ddd --- diff --git a/includes/specials/SpecialLinkSearch.php b/includes/specials/SpecialLinkSearch.php index f474867445..ca89776cdb 100644 --- a/includes/specials/SpecialLinkSearch.php +++ b/includes/specials/SpecialLinkSearch.php @@ -68,10 +68,9 @@ class LinkSearchPage extends QueryPage { * This allows for dependency injection even though we don't control object creation. */ private function initServices() { - global $wgLanguageCode; + global $wgContLang; if ( !$this->linkRenderer ) { - $lang = Language::factory( $wgLanguageCode ); - $titleFormatter = new MediaWikiTitleCodec( $lang, GenderCache::singleton() ); + $titleFormatter = new MediaWikiTitleCodec( $wgContLang, GenderCache::singleton() ); $this->linkRenderer = new MediaWikiPageLinkRenderer( $titleFormatter ); } }