public async Task <Result <List <Customer> > > GetCustomers() { var resultFromClient = await customersClient.GetCustomersAsync(); return(new Result <List <Customer> > { IsSuccess = resultFromClient.IsSuccess, Message = resultFromClient.Message, Value = resultFromClient.IsSuccess ? resultFromClient.Value.Select(c => CustomerConverter.FromDto(c)).ToList() : null }); }
public override Task <ICollection <Customer> > GetAllAsync(CancellationToken token) { return(Client.GetCustomersAsync(Tenant.Id, token)); }