Fixing an issue with cached permissions, work item: 17057

If a role was saved with no permissions at all, the inmemory cache
of role's permission isn't cleared because the trigger was outside
of the loop.

--HG--
branch : 1.x
This commit is contained in:
Louis DeJardin
2010-12-15 16:26:53 -08:00
parent 06868e412a
commit a2e5f82196

View File

@@ -84,8 +84,8 @@ namespace Orchard.Roles.Services {
}
PermissionRecord permissionRecord = _permissionRepository.Get(x => x.Name == permission);
roleRecord.RolesPermissions.Add(new RolesPermissionsRecord { Permission = permissionRecord, Role = roleRecord });
TriggerSignal();
}
TriggerSignal();
}
private string GetFeatureName(string permissionName) {