From 6965ca86f981984cd85818addb7a4d94bb9f9b61 Mon Sep 17 00:00:00 2001 From: Chad Horohoe Date: Fri, 9 Jul 2010 12:43:27 +0000 Subject: [PATCH] Cleanup to r69191: use addParserOutput() instead of addHtml(), specify current rev on Article, use doViewParse() so we can cache the ParserOutput --- includes/diff/DifferenceInterface.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/includes/diff/DifferenceInterface.php b/includes/diff/DifferenceInterface.php index d44823c4be..490d76ded0 100644 --- a/includes/diff/DifferenceInterface.php +++ b/includes/diff/DifferenceInterface.php @@ -444,11 +444,12 @@ CONTROL; $wgOut->addHTML( "\n\n" ); } } elseif( $pCache ) { - $pOutput = ParserCache::singleton()->get( new Article( $this->mTitle ), $wgUser ); + $article = new Article( $this->mTitle, 0 ); + $pOutput = ParserCache::singleton()->get( $article, $wgUser ); if( $pOutput ) { - $wgOut->addHtml( $pOutput->getText() ); + $wgOut->addParserOutput( $pOutput ); } else { - $wgOut->addWikiTextTidy( $this->mNewtext ); + $article->doViewParse(); } } else { $wgOut->addWikiTextTidy( $this->mNewtext ); -- 2.20.1