Browse Source

fix(gdpr): 删除用户账户保留admin账号

pull/1201/head
colin 10 months ago
parent
commit
37afc12b65
  1. 2
      aspnet-core/modules/gdpr/LINGYUN.Abp.Gdpr.Domain.Identity/LINGYUN/Abp/Gdpr/Identity/AbpGdprIdentityUserAccountProvider.cs

2
aspnet-core/modules/gdpr/LINGYUN.Abp.Gdpr.Domain.Identity/LINGYUN/Abp/Gdpr/Identity/AbpGdprIdentityUserAccountProvider.cs

@ -22,7 +22,7 @@ public class AbpGdprIdentityUserAccountProvider : GdprUserAccountProviderBase
// 默认管理员账号保留
// TODO: 保留统一维护的地方?
if (identityUser.UserName == "admin")
if (identityUser.UserName != "admin")
{
(await identityUserManager.DeleteAsync(identityUser)).CheckErrors();
}

Loading…
Cancel
Save