X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fapi%2FApiLogin.php;h=41bec355a7bcbd428607e943dc37815871d21ca5;hb=8ea7953ab57163a575a2ce02d5dbf862d7c9744a;hp=6cf1fad30cd8827f6d23b2da8e4ce43f75d1a859;hpb=f9e21f91e459c40fed6d8f2e76cccbce07e2ba1b;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/api/ApiLogin.php b/includes/api/ApiLogin.php index 6cf1fad30c..41bec355a7 100644 --- a/includes/api/ApiLogin.php +++ b/includes/api/ApiLogin.php @@ -70,14 +70,7 @@ class ApiLogin extends ApiBase { return; } - try { - $this->requirePostedParameters( [ 'password', 'token' ] ); - } catch ( ApiUsageException $ex ) { - // Make this a warning for now, upgrade to an error in 1.29. - foreach ( $ex->getStatusValue()->getErrors() as $error ) { - $this->addDeprecation( $error, 'login-params-in-query-string' ); - } - } + $this->requirePostedParameters( [ 'password', 'token' ] ); $params = $this->extractRequestParams(); @@ -209,7 +202,7 @@ class ApiLogin extends ApiBase { case 'Aborted': $result['reason'] = 'Authentication requires user interaction, ' . - 'which is not supported by action=login.'; + 'which is not supported by action=login.'; if ( $this->getConfig()->get( 'EnableBotPasswords' ) ) { $result['reason'] .= ' To be able to login with action=login, see [[Special:BotPasswords]].'; $result['reason'] .= ' To continue using main-account login, see action=clientlogin.'; @@ -257,6 +250,7 @@ class ApiLogin extends ApiBase { 'token' => [ ApiBase::PARAM_TYPE => 'string', ApiBase::PARAM_REQUIRED => false, // for BC + ApiBase::PARAM_SENSITIVE => true, ApiBase::PARAM_HELP_MSG => [ 'api-help-param-token', 'login' ], ], ]; @@ -272,7 +266,7 @@ class ApiLogin extends ApiBase { } public function getHelpUrls() { - return 'https://www.mediawiki.org/wiki/API:Login'; + return 'https://www.mediawiki.org/wiki/Special:MyLanguage/API:Login'; } /**