Merge "Allow basic grant holders to autocreate accounts"
[lhc/web/wiklou.git] / includes / specialpage / AuthManagerSpecialPage.php
index 0e0a26a..ba7785c 100644 (file)
@@ -13,7 +13,8 @@ use MediaWiki\Session\Token;
  */
 abstract class AuthManagerSpecialPage extends SpecialPage {
        /** @var string[] The list of actions this special page deals with. Subclasses should override
-        * this. */
+        * this.
+        */
        protected static $allowedActions = [
                AuthManager::ACTION_LOGIN, AuthManager::ACTION_LOGIN_CONTINUE,
                AuthManager::ACTION_CREATE, AuthManager::ACTION_CREATE_CONTINUE,
@@ -429,7 +430,7 @@ abstract class AuthManagerSpecialPage extends SpecialPage {
                                // accidentally returning it so best check and fix
                                $status = Status::wrap( $status );
                        } elseif ( is_string( $status ) ) {
-                               $status = Status::newFatal( new RawMessage( '$1', $status ) );
+                               $status = Status::newFatal( new RawMessage( '$1', [ $status ] ) );
                        } elseif ( is_array( $status ) ) {
                                if ( is_string( reset( $status ) ) ) {
                                        $status = Status::newFatal( ...$status );
@@ -710,7 +711,6 @@ abstract class AuthManagerSpecialPage extends SpecialPage {
         * are shown closer to the bottom; weight defaults to 0. Negative weight is allowed.)
         * Keep order if weights are equal.
         * @param array &$formDescriptor
-        * @return array
         */
        protected static function sortFormDescriptorFields( array &$formDescriptor ) {
                $i = 0;