$user = $this->getUser();
// make sure the user is allowed
- if ( !$user->isAllowed( 'changetags' ) ) {
- $this->dieUsage( "You don't have permission to add or remove change tags from individual edits",
- 'permissiondenied' );
- }
+ $this->checkUserRightsAny( 'changetags' );
if ( $user->isBlocked() ) {
$this->dieBlocked( $user->getBlock() );
if ( !$valid ) {
$idResult['status'] = 'error';
- $idResult += $this->parseMsg( [ "nosuch$type", $id ] );
+ // Messages: apierror-nosuchrcid apierror-nosuchrevid apierror-nosuchlogid
+ $idResult += $this->getErrorFormatter()->formatMessage( [ "apierror-nosuch$type", $id ] );
return $idResult;
}