* Fix display of old recentchanges records for page moves
authorBrion Vibber <brion@users.mediawiki.org>
Mon, 28 Nov 2005 04:32:39 +0000 (04:32 +0000)
committerBrion Vibber <brion@users.mediawiki.org>
Mon, 28 Nov 2005 04:32:39 +0000 (04:32 +0000)
RELEASE-NOTES
includes/ChangesList.php

index 4eef4f0..0b5aa9f 100644 (file)
@@ -259,6 +259,8 @@ fully support the editing toolbar, but was found to be too confusing.
 * Substitute {{REVISIONID}} correctly in diff display
 * (bug 4090) Fix diff links in Special:Recentchangeslinked
 * (bug 4093) '&bot=1' in Special:Contributions now propagate to other links
+* Fix display of old recentchanges records for page moves
+
 
 === Caveats ===
 
index 6d90e57..ecf261f 100644 (file)
@@ -153,7 +153,7 @@ class ChangesList {
        }
 
 
-       function insertMove(&$s) {
+       function insertMove( &$s, $rc ) {
                # Diff
                $s .= '(' . $this->message['diff'] . ') (';
                # Hist
@@ -161,7 +161,7 @@ class ChangesList {
                        ') . . ';
 
                # "[[x]] moved to [[y]]"
-               $msg = ( $rc_type == RC_MOVE ) ? '1movedto2' : '1movedto2_redir';
+               $msg = ( $rc->mAttribs['rc_type'] == RC_MOVE ) ? '1movedto2' : '1movedto2_redir';
                $s .= wfMsg( $msg, $this->skin->makeKnownLinkObj( $rc->getTitle(), '', 'redirect=no' ),
                        $this->skin->makeKnownLinkObj( $rc->getMovedToTitle(), '' ) );
        }
@@ -323,7 +323,7 @@ class OldChangesList extends ChangesList {
 
                // moved pages
                if ( $rc_type == RC_MOVE || $rc_type == RC_MOVE_OVER_REDIRECT ) {
-                       $this->insertMove($s);
+                       $this->insertMove( $s, $rc );
                // log entries
                } elseif( $rc_namespace == NS_SPECIAL && preg_match( '!^Log/(.*)$!', $rc_title, $matches ) ) {
                        $this->insertLog($s, $rc->getTitle(), $matches[1]);