mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Echo
synced 2024-11-28 01:30:15 +00:00
Use setContentLang instead of setMwGlobals
This sets $wgLanguageCode appropriately. It will also be necessary when $wgContLang becomes a service, in which case setting the global directly will not work correctly. Bug: T200246 Change-Id: I4aaf1c641ec6abef214eb96c0e4b42a67488ac00
This commit is contained in:
parent
6e0339b7e0
commit
83be57fe01
|
@ -949,11 +949,10 @@ TEXT
|
|||
private function setupTestRevisionsForEventGeneration( $newId, $oldId, $username, $lang, $pages,
|
||||
$title, $summary = ''
|
||||
) {
|
||||
$langObj = Language::factory( $lang );
|
||||
// Content language is used by the code that interprets the namespace part of titles
|
||||
// (Title::getTitleParser), so should be the fake language ;)
|
||||
$this->setContentLang( $lang );
|
||||
$this->setMwGlobals( [
|
||||
// this global is used by the code that interprets the namespace part of
|
||||
// titles (Title::getTitleParser), so should be the fake language ;)
|
||||
'wgContLang' => $langObj,
|
||||
// this one allows Mediawiki:xyz pages to be set as messages
|
||||
'wgUseDatabaseMessages' => true
|
||||
] );
|
||||
|
|
Loading…
Reference in a new issue