Call method with the same name it's defined with
[lhc/web/wiklou.git] / includes / api / ApiUserrights.php
index 870201e..5e068cb 100644 (file)
@@ -66,13 +66,13 @@ class ApiUserrights extends ApiBase {
                $form->setContext( $this->getContext() );
                $status = $form->fetchUser( $params['user'] );
                if ( !$status->isOK() ) {
-                       $errors = $status->getErrorsArray();
-                       $this->dieUsageMsg( $errors[0] );
+                       $this->dieStatus( $status );
                } else {
                        $user = $status->value;
                }
 
                $this->mUser = $user;
+
                return $user;
        }