X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fapi%2FApiManageTags.php;h=6cd717a680fc988f55fc6ff5819c0893ac943403;hb=529fc12d2ad2032337594389448fdb5b55802830;hp=42de16101856a7aca837ef692c7b446eb67961a5;hpb=39fb8a4f531256e122fa4c01d4417d23d168f299;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/api/ApiManageTags.php b/includes/api/ApiManageTags.php index 42de161018..6cd717a680 100644 --- a/includes/api/ApiManageTags.php +++ b/includes/api/ApiManageTags.php @@ -31,10 +31,10 @@ class ApiManageTags extends ApiBase { // make sure the user is allowed if ( $params['operation'] !== 'delete' - && !$this->getUser()->isAllowed( 'managechangetags' ) + && !$this->getPermissionManager()->userHasRight( $user, 'managechangetags' ) ) { $this->dieWithError( 'tags-manage-no-permission', 'permissiondenied' ); - } elseif ( !$this->getUser()->isAllowed( 'deletechangetags' ) ) { + } elseif ( !$this->getPermissionManager()->userHasRight( $user, 'deletechangetags' ) ) { $this->dieWithError( 'tags-delete-no-permission', 'permissiondenied' ); }