r34613 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r34612‎ | r34613 | r34614 >
Date:13:45, 11 May 2008
Author:aaron
Status:old
Tags:
Comment:
Slave lag
Modified paths:
  • /trunk/extensions/FlaggedRevs/FlaggedRevs.php (modified) (history)

Diff [purge]

Index: trunk/extensions/FlaggedRevs/FlaggedRevs.php
@@ -1826,12 +1826,11 @@
18271827 foreach( self::$dimensions as $tag => $minQL ) {
18281828 $flags[$tag] = 1;
18291829 }
1830 - # Select the version that is now current. Create a new article object
1831 - # to avoid using one with outdated field data.
1832 - $article = new Article( $article->getTitle() );
1833 - $newRev = Revision::newFromId( $article->getLatest() );
1834 - self::autoReviewEdit( $article, $user, $rev->getText(), $newRev, $flags );
1835 - self::articleLinksUpdate( $article ); // lame...
 1830+ $newRev = Revision::newFromId( $article->getTitle()->getLatestRevID(GAID_FOR_UPDATE) );
 1831+ if( $newRev ) {
 1832+ self::autoReviewEdit( $article, $user, $rev->getText(), $newRev, $flags );
 1833+ self::articleLinksUpdate( $article ); // lame...
 1834+ }
18361835 }
18371836 if( $wgFlaggedArticle ) {
18381837 $wgFlaggedArticle->skipReviewDiff = true; // Don't jump to diff...

Status & tagging log