From: Rob Church Date: Wed, 22 Aug 2007 07:24:30 +0000 (+0000) Subject: Tweak comment; people seem to whine about this one, not reading past the mt_rand... X-Git-Tag: 1.31.0-rc.0~51700 X-Git-Url: http://git.cyclocoop.org/%7B%24admin_url%7Dcompta/comptes/journal.php?a=commitdiff_plain;h=e313f182de008e0acc9f61da3fb2d4a57f699e27;p=lhc%2Fweb%2Fwiklou.git Tweak comment; people seem to whine about this one, not reading past the mt_rand() bit, and criticising us... --- diff --git a/includes/Article.php b/includes/Article.php index 32ce420e06..5bb5915eb3 100644 --- a/includes/Article.php +++ b/includes/Article.php @@ -2403,12 +2403,11 @@ class Article { $u = new LinksUpdate( $this->mTitle, $poutput ); $u->doUpdate(); - if ( wfRunHooks( 'ArticleEditUpdatesDeleteFromRecentchanges', array( &$this ) ) ) { - wfSeedRandom(); + if( wfRunHooks( 'ArticleEditUpdatesDeleteFromRecentchanges', array( &$this ) ) ) { if ( 0 == mt_rand( 0, 99 ) ) { - # Periodically flush old entries from the recentchanges table. + // Flush old entries from the `recentchanges` table; we do this on + // random requests so as to avoid an increase in writes for no good reason global $wgRCMaxAge; - $dbw = wfGetDB( DB_MASTER ); $cutoff = $dbw->timestamp( time() - $wgRCMaxAge ); $recentchanges = $dbw->tableName( 'recentchanges' );