diff options
Diffstat (limited to 'MLEB/Translate/api/ApiGroupReview.php')
-rw-r--r-- | MLEB/Translate/api/ApiGroupReview.php | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/MLEB/Translate/api/ApiGroupReview.php b/MLEB/Translate/api/ApiGroupReview.php index 67583854..cb448ccd 100644 --- a/MLEB/Translate/api/ApiGroupReview.php +++ b/MLEB/Translate/api/ApiGroupReview.php @@ -22,7 +22,7 @@ class ApiGroupReview extends ApiBase { $code = $requestParams['language']; if ( !$group || MessageGroups::isDynamic( $group ) ) { - $this->dieWithError( [ 'apierror-missingparam', 'group' ] ); + $this->dieWithError( [ 'apierror-badparameter', 'group' ] ); } $stateConfig = $group->getMessageGroupStates()->getStates(); if ( !$stateConfig ) { @@ -35,11 +35,9 @@ class ApiGroupReview extends ApiBase { $this->dieBlocked( $user->getBlock() ); } - $requestParams = $this->extractRequestParams(); - $languages = Language::fetchLanguageNames(); if ( !isset( $languages[$code] ) ) { - $this->dieWithError( [ 'apierror-missingparam', 'language' ] ); + $this->dieWithError( [ 'apierror-badparameter', 'language' ] ); } $targetState = $requestParams['state']; |