From: daniel Date: Tue, 15 May 2012 13:26:29 +0000 (+0200) Subject: fix usage of wgOut in Article X-Git-Tag: 1.31.0-rc.0~22097^2^2~165 X-Git-Url: https://git.cyclocoop.org/%27.%24link.%27?a=commitdiff_plain;h=ffa0efffd277dc5fc9e26829e2f22f20cf2d5a26;p=lhc%2Fweb%2Fwiklou.git fix usage of wgOut in Article --- diff --git a/includes/Article.php b/includes/Article.php index 00b2107c3e..defc9e19f8 100644 --- a/includes/Article.php +++ b/includes/Article.php @@ -628,10 +628,10 @@ class Article extends Page { wfDebug( __METHOD__ . ": showing CSS/JS source\n" ); $this->showCssOrJsPage(); $outputDone = true; - } elseif( !wfRunHooks( 'ArticleContentViewCustom', array( $this->fetchContentObject(), $this->getTitle(), $wgOut ) ) ) { + } elseif( !wfRunHooks( 'ArticleContentViewCustom', array( $this->fetchContentObject(), $this->getTitle(), $outputPage ) ) ) { # Allow extensions do their own custom view for certain pages $outputDone = true; - } elseif( Hooks::isRegistered( 'ArticleViewCustom' ) && !wfRunHooks( 'ArticleViewCustom', array( $this->fetchContent(), $this->getTitle(), $wgOut ) ) ) { #FIXME: fetchContent() is deprecated! + } elseif( Hooks::isRegistered( 'ArticleViewCustom' ) && !wfRunHooks( 'ArticleViewCustom', array( $this->fetchContent(), $this->getTitle(), $outputPage ) ) ) { #FIXME: fetchContent() is deprecated! # Allow extensions do their own custom view for certain pages $outputDone = true; } else { @@ -643,7 +643,7 @@ class Article extends Page { $outputPage->addHTML( $this->viewRedirect( $rt ) ); # Parse just to get categories, displaytitle, etc. $this->mParserOutput = $content->getParserOutput( $this->getContext(), $oldid, $parserOptions, false ); - $wgOut->addParserOutputNoText( $this->mParserOutput ); + $outputPage->addParserOutputNoText( $this->mParserOutput ); $outputDone = true; } }