Pass context page to doc-page-show message

Bug: T381185
Change-Id: I95b082a3264fe575a893530f5f9215a949240db5
This commit is contained in:
Pppery 2024-11-29 14:06:01 -05:00
parent 9d99710d12
commit cac5e08e27

View file

@ -442,8 +442,12 @@ class Hooks implements
public function onArticleViewHeader( $article, &$outputDone, &$pcache ) {
$title = $article->getTitle();
if ( Scribunto::isDocPage( $title, $forModule ) ) {
$article->getContext()->getOutput()->addHTML(
wfMessage( 'scribunto-doc-page-header', $forModule->getPrefixedText() )->parseAsBlock()
$context = $article->getContext();
$context->getOutput()->addHTML(
$context->msg(
'scribunto-doc-page-header',
$forModule->getPrefixedText()
)->parseAsBlock()
);
}
}