X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fapi%2FApiCheckToken.php;h=480915e60cf880a613c46073ba78391259e44485;hb=aa0d88c1ce70f5a7bb9db2f738b3081b6c64c6f4;hp=dd88b5fe3a5e2800254934f8c2bc5f1a0735d66c;hpb=c406d0746cedf1e9e34d1d8a50361451f44723db;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/api/ApiCheckToken.php b/includes/api/ApiCheckToken.php index dd88b5fe3a..480915e60c 100644 --- a/includes/api/ApiCheckToken.php +++ b/includes/api/ApiCheckToken.php @@ -43,9 +43,7 @@ class ApiCheckToken extends ApiBase { ); if ( substr( $token, -strlen( urldecode( Token::SUFFIX ) ) ) === urldecode( Token::SUFFIX ) ) { - $this->setWarning( - "Check that symbols such as \"+\" in the token are properly percent-encoded in the URL." - ); + $this->addWarning( 'apiwarn-checktoken-percentencoding' ); } if ( $tokenObj->match( $token, $maxage ) ) { @@ -75,6 +73,7 @@ class ApiCheckToken extends ApiBase { 'token' => [ ApiBase::PARAM_TYPE => 'string', ApiBase::PARAM_REQUIRED => true, + ApiBase::PARAM_SENSITIVE => true, ], 'maxtokenage' => [ ApiBase::PARAM_TYPE => 'integer',