From f84ef998413ee6eb2fe24ee73a48ca62e2e00e88 Mon Sep 17 00:00:00 2001 From: Aaron Schulz Date: Sun, 4 Jan 2009 12:27:08 +0000 Subject: [PATCH] Expand ArticleRollbackComplete hook to include reverted rev --- docs/hooks.txt | 1 + includes/Article.php | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/hooks.txt b/docs/hooks.txt index fa3c011fb6..04b1e2ac8e 100644 --- a/docs/hooks.txt +++ b/docs/hooks.txt @@ -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 diff --git a/includes/Article.php b/includes/Article.php index 74bf29ce8c..2ffd24a55f 100644 --- a/includes/Article.php +++ b/includes/Article.php @@ -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, -- 2.20.1