Exemple #1
0
        /// <summary>
        ///     Removes a single permission.
        ///     This both removes the permission from the db, and also removes the permission from all the roles that contain the
        ///     permission.
        /// </summary>
        public async Task DeletePermission(Permission permission)
        {
            // TODO: remove permissions from granular permissions
            await _roleService.RemovePermissionsFromRoles(permission.Id, permission.Grain, permission.SecurableItem);

            await _permissionStore.Delete(permission);
        }