Fix usage of ApiBase::PARAM_* deprecated constants

The ones that are replaced with ParamValidator

Bug: T275455
Change-Id: I9ed72118c05cff879142ed89a3906c077413d25b
This commit is contained in:
gerritbot 2022-04-04 01:26:15 +02:00 committed by Ladsgroup
parent 15fd46f064
commit 731d530534
3 changed files with 6 additions and 6 deletions

View file

@ -358,7 +358,7 @@ class ApiDiscussionToolsEdit extends ApiBase {
ParamValidator::PARAM_REQUIRED => true, ParamValidator::PARAM_REQUIRED => true,
], ],
'formtoken' => [ 'formtoken' => [
ApiBase::PARAM_TYPE => 'string', ParamValidator::PARAM_TYPE => 'string',
StringDef::PARAM_MAX_CHARS => 16, StringDef::PARAM_MAX_CHARS => 16,
], ],
'commentname' => null, 'commentname' => null,
@ -380,7 +380,7 @@ class ApiDiscussionToolsEdit extends ApiBase {
ParamValidator::PARAM_TYPE => 'string', ParamValidator::PARAM_TYPE => 'string',
], ],
'useskin' => [ 'useskin' => [
ApiBase::PARAM_TYPE => array_keys( ParamValidator::PARAM_TYPE => array_keys(
MediaWikiServices::getInstance()->getSkinFactory()->getInstalledSkins() MediaWikiServices::getInstance()->getSkinFactory()->getInstalledSkins()
), ),
ApiBase::PARAM_HELP_MSG => 'apihelp-parse-param-useskin', ApiBase::PARAM_HELP_MSG => 'apihelp-parse-param-useskin',

View file

@ -57,7 +57,7 @@ class ApiDiscussionToolsGetSubscriptions extends ApiBase {
return [ return [
'commentname' => [ 'commentname' => [
ParamValidator::PARAM_REQUIRED => true, ParamValidator::PARAM_REQUIRED => true,
ApiBase::PARAM_ISMULTI => true, ParamValidator::PARAM_ISMULTI => true,
], ],
]; ];
} }

View file

@ -88,9 +88,9 @@ class ApiDiscussionToolsPageInfo extends ApiBase {
], ],
'oldid' => null, 'oldid' => null,
'prop' => [ 'prop' => [
ApiBase::PARAM_DFLT => 'transcludedfrom', ParamValidator::PARAM_DEFAULT => 'transcludedfrom',
ApiBase::PARAM_ISMULTI => true, ParamValidator::PARAM_ISMULTI => true,
ApiBase::PARAM_TYPE => [ ParamValidator::PARAM_TYPE => [
'transcludedfrom', 'transcludedfrom',
'threaditemshtml' 'threaditemshtml'
], ],