From c0f875cb0150e95d32727afdde87811db2b7c36d Mon Sep 17 00:00:00 2001 From: Antoine Musso Date: Tue, 29 Mar 2005 16:38:30 +0000 Subject: [PATCH] New articles fetched revision assumed to be 0. Correctly display {{REVISIONID}} on diff page. --- includes/Article.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/includes/Article.php b/includes/Article.php index 091adc3004..6bf2ca654f 100644 --- a/includes/Article.php +++ b/includes/Article.php @@ -69,7 +69,7 @@ class Article { $this->mTouched = '19700101000000'; $this->mForUpdate = false; $this->mIsRedirect = false; - $this->mRevIdFetched = false; + $this->mRevIdFetched = 0; } /** @@ -646,8 +646,12 @@ class Article { if ( !is_null( $diff ) ) { require_once( 'DifferenceEngine.php' ); $wgOut->setPageTitle( $this->mTitle->getPrefixedText() ); + $de = new DifferenceEngine( $oldid, $diff, $rcid ); + // DifferenceEngine directly fetched the revision: + $this->mRevIdFetched = $de->mNewid; $de->showDiffPage(); + if( $diff == 0 ) { # Run view updates for current revision only $this->viewUpdates(); -- 2.20.1