* @file
*/
+use MediaWiki\MediaWikiServices;
+
/**
* A query module to list all langlinks (links to corresponding foreign language pages).
*
}
public function getAllowedParams() {
- global $wgContLang;
return [
'prop' => [
ApiBase::PARAM_ISMULTI => true,
'descending'
]
],
- 'inlanguagecode' => $wgContLang->getCode(),
+ 'inlanguagecode' => MediaWikiServices::getInstance()->getContentLanguage()->getCode(),
'limit' => [
ApiBase::PARAM_DFLT => 10,
ApiBase::PARAM_TYPE => 'limit',