HomePhabricator

Re-apply: Factors out permissions check from User into PermissionManager service

Authored by Vedmaka on Apr 9 2019, 6:58 AM.

Description

Re-apply: Factors out permissions check from User into PermissionManager service

Was reverted by I549810a4cd2e424cc4a438887d2f24614a24cc00 due to
T224607.

Original change by Vedmaka Wakalaka was
Ia0d840b772ea5f20c9594ce151cc57adc270e48b.

Original commit message:

The following methods should are factored out of the User class into PermissionManager,
leaving only deprecated stubs:

  • User::isAllowed -> PermissionManager::userHasRight
  • User::getRights -> PermissionManager::getUserPermissions
  • User::groupHasPermission -> PermissionManager::groupHasPermission
  • User::getGroupPermissions -> PermissionManager::getGroupPermissions -User::getGroupsWithPermission -> PermissionManager::getGroupsWithPermission
  • User::groupHasPermission -> PermissionManager::groupHasPermission
  • User::isEveryoneAllowed -> PermissionManager::isEveryoneAllowed
  • User::getAllRights -> PermissionManager::getAllPermissions

Depends-On: I7909e9bd6bbfbd708c0a00b861a9b22a38c6665d

Bug: T218558
Bug: T223294
Change-Id: I8899240378f636ea70f447616710516c0a3c5c31

Details