public IHttpClient Decorate( IHttpClient httpClient, IHttpApiConfiguration httpApiConfiguration) { var httpApiWithRetrying = httpApiConfiguration as IHttpApiWithRetrying; if (httpApiWithRetrying is null) { return(httpClient); } return(httpClient.AddRetrying(httpApiWithRetrying, _retryManager, _callbacks)); }