Browse Source

Only changes role name if it actual changed.

pull/20533/head
maliming 1 year ago
parent
commit
91dca5b53d
No known key found for this signature in database GPG Key ID: A646B9CB645ECEA4
  1. 5
      modules/identity/src/Volo.Abp.Identity.Application/Volo/Abp/Identity/IdentityRoleAppService.cs

5
modules/identity/src/Volo.Abp.Identity.Application/Volo/Abp/Identity/IdentityRoleAppService.cs

@ -77,7 +77,10 @@ public class IdentityRoleAppService : IdentityAppServiceBase, IIdentityRoleAppSe
role.SetConcurrencyStampIfNotNull(input.ConcurrencyStamp);
(await RoleManager.SetRoleNameAsync(role, input.Name)).CheckErrors();
if (role.Name != input.Name)
{
(await RoleManager.SetRoleNameAsync(role, input.Name)).CheckErrors();
}
role.IsDefault = input.IsDefault;
role.IsPublic = input.IsPublic;

Loading…
Cancel
Save