Pass the old article ID in the ArticleDeleteComplete hook, to allow, for example...
authorAndrew Garrett <werdna@users.mediawiki.org>
Mon, 28 Apr 2008 12:34:27 +0000 (12:34 +0000)
committerAndrew Garrett <werdna@users.mediawiki.org>
Mon, 28 Apr 2008 12:34:27 +0000 (12:34 +0000)
includes/Article.php

index 18be4da..e56febf 100644 (file)
@@ -2217,6 +2217,8 @@ class Article {
        function doDelete( $reason, $suppress = false ) {
                global $wgOut, $wgUser;
                wfDebug( __METHOD__."\n" );
+               
+               $id = $this->getId();
 
                if (wfRunHooks('ArticleDelete', array(&$this, &$wgUser, &$reason))) {
                        if ( $this->doDeleteArticle( $reason, $suppress ) ) {
@@ -2229,7 +2231,7 @@ class Article {
 
                                $wgOut->addWikiMsg( 'deletedtext', $deleted, $loglink );
                                $wgOut->returnToMain( false );
-                               wfRunHooks('ArticleDeleteComplete', array(&$this, &$wgUser, $reason));
+                               wfRunHooks('ArticleDeleteComplete', array(&$this, &$wgUser, $reason, $id));
                        } else {
                                $wgOut->showFatalError( wfMsg( 'cannotdelete' ) );
                        }