From 0ae5e029901b466512a76d4edcaeddd3fe2831af Mon Sep 17 00:00:00 2001 From: Antoine Musso Date: Sun, 4 Dec 2005 20:51:02 +0000 Subject: [PATCH] * really comment commented live hack (some calls were still around) * redundant ip='' * code formatting --- includes/RecentChange.php | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/includes/RecentChange.php b/includes/RecentChange.php index 2f036750f0..3c5383c0bc 100644 --- a/includes/RecentChange.php +++ b/includes/RecentChange.php @@ -132,20 +132,22 @@ class RecentChange # Update old rows, if necessary if ( $this->mAttribs['rc_type'] == RC_EDIT ) { - $oldid = $this->mAttribs['rc_last_oldid']; - $ns = $this->mAttribs['rc_namespace']; - $title = $this->mAttribs['rc_title']; $lastTime = $this->mExtra['lastTimestamp']; - $now = $this->mAttribs['rc_timestamp']; - $curId = $this->mAttribs['rc_cur_id']; + #$now = $this->mAttribs['rc_timestamp']; + #$curId = $this->mAttribs['rc_cur_id']; # Don't bother looking for entries that have probably # been purged, it just locks up the indexes needlessly. global $wgRCMaxAge; $age = time() - wfTimestamp( TS_UNIX, $lastTime ); if( $age < $wgRCMaxAge ) { - # live hack, will commit once tested - kate + # live hack, will commit once tested - kate # Update rc_this_oldid for the entries which were current + # + #$oldid = $this->mAttribs['rc_last_oldid']; + #$ns = $this->mAttribs['rc_namespace']; + #$title = $this->mAttribs['rc_title']; + # #$dbw->update( 'recentchanges', # array( /* SET */ # 'rc_this_oldid' => $oldid @@ -327,7 +329,7 @@ class RecentChange } /* static */ function notifyMoveOverRedirect( $timestamp, &$oldTitle, &$newTitle, &$user, $comment, $ip='' ) { - RecentChange::notifyMove( $timestamp, $oldTitle, $newTitle, $user, $comment, $ip='', true ); + RecentChange::notifyMove( $timestamp, $oldTitle, $newTitle, $user, $comment, $ip, true ); } # A log entry is different to an edit in that previous revisions are @@ -451,11 +453,12 @@ class RecentChange if ( isset( $oldSize ) && isset( $newSize ) ) { $szdiff = $newSize - $oldSize; - if ($szdiff < -500) + if ($szdiff < -500) { $szdiff = "\002$szdiff\002"; - else if ($szdiff >= 0) - $szdiff = "+$szdiff"; - $szdiff = "($szdiff)"; + } elseif ($szdiff >= 0) { + $szdiff = '+' . $szdiff ; + } + $szdiff = '(' . $szdiff . ')' ; } else { $szdiff = ''; } -- 2.20.1