* @return string
*/
public function parse( $text, $lineStart = false ) {
- global $wgParser;
+ $parser = MediaWikiServices::getInstance()->getParser();
try {
- $out = $wgParser->parse( $text, $this->parserTitle, $this->parserOptions, $lineStart );
+ $out = $parser->parse( $text, $this->parserTitle, $this->parserOptions, $lineStart );
$html = $out->getText( [
'enableSectionEditLinks' => false,
'unwrap' => true,
}
if ( !$caches ) {
- $key = 'config-no-cache-apcu';
- $this->showMessage( $key );
+ $this->showMessage( 'config-no-cache-apcu' );
}
$this->setVar( '_Caches', $caches );