Localisation updates from https://translatewiki.net.
[lhc/web/wiklou.git] / includes / api / ApiMove.php
index 1aa0d11..7fb6303 100644 (file)
@@ -166,6 +166,11 @@ class ApiMove extends ApiBase {
                        return $permStatus;
                }
 
+               // Check suppressredirect permission
+               if ( !$this->getUser()->isAllowed( 'suppressredirect' ) ) {
+                       $createRedirect = true;
+               }
+
                return $mp->move( $this->getUser(), $reason, $createRedirect );
        }
 
@@ -246,7 +251,7 @@ class ApiMove extends ApiBase {
                return 'csrf';
        }
 
-       public function getExamplesMessages() {
+       protected function getExamplesMessages() {
                return array(
                        'action=move&from=Badtitle&to=Goodtitle&token=123ABC&' .
                                'reason=Misspelled%20title&movetalk=&noredirect='