Aaron is lazy, but right :)
[lhc/web/wiklou.git] / includes / FileDeleteForm.php
index b7c544c..5177d35 100644 (file)
@@ -67,7 +67,7 @@ class FileDeleteForm {
                        $reason = $this->DeleteReasonList;
                        if ( $reason != 'other' && $this->DeleteReason != '') {
                                // Entry from drop down menu + additional comment
-                               $reason .= ': ' . $this->DeleteReason;
+                               $reason .= wfMsgForContent( 'colon-separator' ) . $this->DeleteReason;
                        } elseif ( $reason == 'other' ) {
                                $reason = $this->DeleteReason;
                        }
@@ -108,12 +108,13 @@ class FileDeleteForm {
                                $id = $title->getArticleID( GAID_FOR_UPDATE );
                                // Need to delete the associated article
                                $article = new Article( $title );
-                               if( wfRunHooks('ArticleDelete', array(&$article, &$wgUser, &$reason)) ) {
+                               $error = '';
+                               if( wfRunHooks('ArticleDelete', array(&$article, &$wgUser, &$reason, &$error)) ) {
                                        if( $article->doDeleteArticle( $reason, $suppress, $id ) ) {
                                                global $wgRequest;
                                                if( $wgRequest->getCheck( 'wpWatch' ) ) {
                                                        $article->doWatch();
-                                               } elseif( $this->mTitle->userIsWatching() ) {
+                                               } elseif( $title->userIsWatching() ) {
                                                        $article->doUnwatch();
                                                }
                                                wfRunHooks('ArticleDeleteComplete', array(&$article, &$wgUser, $reason, $id));