public virtual async Task ChangePasswordAsync(ChangePasswordInput input) { var currentUser = await UserManager.GetByIdAsync(CurrentUser.GetId()); if (currentUser.IsExternal) { throw new BusinessException(code: IdentityErrorCodes.ExternalUserPasswordChange); } if (currentUser.PasswordHash == null) { (await UserManager.AddPasswordAsync(currentUser, input.NewPassword)).CheckErrors(); return; } (await UserManager.ChangePasswordAsync(currentUser, input.CurrentPassword, input.NewPassword)).CheckErrors(); }
public virtual async Task ChangePasswordAsync(ChangePasswordInput input) { var currentUser = await _userManager.GetByIdAsync(CurrentUser.GetId()); (await _userManager.ChangePasswordAsync(currentUser, input.CurrentPassword, input.NewPassword)).CheckErrors(); }
public Task ChangePasswordAsync(ChangePasswordInput input) { return(_profileAppService.ChangePasswordAsync(input)); }
public virtual Task ChangePasswordAsync(ChangePasswordInput input) { return(ProfileAppService.ChangePasswordAsync(input)); }