Add API help messages to ApiCreateTempUserTrait
The parameters are always the same, so there’s no point in requiring each API module to document them separately. Just reuse action=edit’s messages everywhere. (DiscussionTools [1] and VisualEditor [2] already do this without using the trait.) [1]:46a3e15dfb/includes/ApiDiscussionToolsEdit.php (491)[2]:b224d16b64/includes/ApiVisualEditorEdit.php (608)Bug: T357030 Change-Id: I1c8b6b48a0e0ddb4cd10a0279f8f75ba0ab5afc5
This commit is contained in:
parent
6e1bca9cf4
commit
a3ef9bde23
1 changed files with 3 additions and 0 deletions
|
|
@ -56,14 +56,17 @@ trait ApiCreateTempUserTrait {
|
|||
return [
|
||||
'returnto' => [
|
||||
ParamValidator::PARAM_TYPE => 'title',
|
||||
ApiBase::PARAM_HELP_MSG => 'apihelp-edit-param-returnto',
|
||||
],
|
||||
'returntoquery' => [
|
||||
ParamValidator::PARAM_TYPE => 'string',
|
||||
ParamValidator::PARAM_DEFAULT => '',
|
||||
ApiBase::PARAM_HELP_MSG => 'apihelp-edit-param-returntoquery',
|
||||
],
|
||||
'returntoanchor' => [
|
||||
ParamValidator::PARAM_TYPE => 'string',
|
||||
ParamValidator::PARAM_DEFAULT => '',
|
||||
ApiBase::PARAM_HELP_MSG => 'apihelp-edit-param-returntoanchor',
|
||||
],
|
||||
];
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue