Expand ArticleRollbackComplete hook to include reverted rev
authorAaron Schulz <aaron@users.mediawiki.org>
Sun, 4 Jan 2009 12:27:08 +0000 (12:27 +0000)
committerAaron Schulz <aaron@users.mediawiki.org>
Sun, 4 Jan 2009 12:27:08 +0000 (12:27 +0000)
docs/hooks.txt
includes/Article.php

index fa3c011..04b1e2a 100644 (file)
@@ -420,6 +420,7 @@ $oldPageID: the page ID of the revision when archived (may be null)
 $article: the article that was edited
 $user: the user who did the rollback
 $revision: the revision the page was reverted back to
+$current: the reverted revision
 
 'ArticleSave': before an article is saved
 $article: the article (object) being saved
index 74bf29c..2ffd24a 100644 (file)
@@ -2658,7 +2658,7 @@ class Article {
                        $revId = false;
                }
 
-               wfRunHooks( 'ArticleRollbackComplete', array( $this, $wgUser, $target ) );
+               wfRunHooks( 'ArticleRollbackComplete', array( $this, $wgUser, $target, $current ) );
 
                $resultDetails = array(
                        'summary' => $summary,