Make sure all RC entries for page are cleared on delete (bug 15655)
authorAaron Schulz <aaron@users.mediawiki.org>
Sat, 4 Oct 2008 22:00:44 +0000 (22:00 +0000)
committerAaron Schulz <aaron@users.mediawiki.org>
Sat, 4 Oct 2008 22:00:44 +0000 (22:00 +0000)
includes/Article.php

index 88a7bfa..399c77e 100644 (file)
@@ -2493,6 +2493,11 @@ class Article {
                # If using cleanup triggers, we can skip some manual deletes
                if ( !$dbw->cleanupTriggers() ) {
                        # Clean up recentchanges entries...
+                       $dbw->delete( 'recentchanges',
+                               array( 'rc_type != '.RC_LOG, 
+                                       'rc_namespace' => $this->mTitle->getNamespace(),
+                                       'rc_title' => $this->mTitle->getDBKey() ),
+                               __METHOD__ );
                        $dbw->delete( 'recentchanges',
                                array( 'rc_type != '.RC_LOG, 'rc_cur_id' => $id ),
                                __METHOD__ );