public override async Task <Unit> Handle ( FetchWeatherForecastsAction aFetchWeatherForecastsAction, CancellationToken aCancellationToken ) { var getWeatherForecastsRequest = new GetWeatherForecastsRequest { Days = 10 }; GetWeatherForecastsResponse getWeatherForecastsResponse = await WebApiService.GetResponse <GetWeatherForecastsResponse>(getWeatherForecastsRequest) .ConfigureAwait(false); WeatherForecastsState._WeatherForecasts = getWeatherForecastsResponse.WeatherForecasts; return(Unit.Value); }
public async Task <TResponse> GetResponse <TResponse>(IApiRequest aApiRequest) => await WebApiService.GetResponse <TResponse>(aApiRequest);