Pass user to WikiPage::doDeleteArticleReal
[lhc/web/wiklou.git] / includes / api / ApiDelete.php
index e455f71..6279dfd 100644 (file)
@@ -131,7 +131,7 @@ class ApiDelete extends ApiBase {
                $error = '';
 
                // Luckily, Article.php provides a reusable delete function that does the hard work for us
-               return $page->doDeleteArticleReal( $reason, false, 0, true, $error );
+               return $page->doDeleteArticleReal( $reason, false, 0, true, $error, $user );
        }
 
        /**
@@ -214,7 +214,7 @@ class ApiDelete extends ApiBase {
                return 'csrf';
        }
 
-       public function getExamplesMessages() {
+       protected function getExamplesMessages() {
                return array(
                        'action=delete&title=Main%20Page&token=123ABC'
                                => 'apihelp-delete-example-simple',