diff --git a/aspnet-core/modules/BasicManagement/src/Lion.AbpPro.BasicManagement.Application/Users/UserAppService.cs b/aspnet-core/modules/BasicManagement/src/Lion.AbpPro.BasicManagement.Application/Users/UserAppService.cs index 2d676b26..7650f165 100644 --- a/aspnet-core/modules/BasicManagement/src/Lion.AbpPro.BasicManagement.Application/Users/UserAppService.cs +++ b/aspnet-core/modules/BasicManagement/src/Lion.AbpPro.BasicManagement.Application/Users/UserAppService.cs @@ -132,15 +132,15 @@ namespace Lion.AbpPro.BasicManagement.Users if (identityUser.PasswordHash == null) { result = await _userManager.AddPasswordAsync(identityUser, input.NewPassword); + result.CheckErrors(); } else { result = await _userManager.ChangePasswordAsync(identityUser, input.CurrentPassword, input.NewPassword); + result.CheckErrors(); } - return !result.Succeeded - ? throw new BusinessException("Volo.Abp.Identity:" + result?.Errors?.FirstOrDefault()?.Code) - : result.Succeeded; + return result.Succeeded; } ///