diff --git a/composer.json b/composer.json index d2bd56e2a..f33b591fb 100644 --- a/composer.json +++ b/composer.json @@ -23,7 +23,7 @@ "require": { "php": "^5.6 || ^7.0", "ext-xml": "*", - "php-http/client-common": "^1.5", + "php-http/client-common": "^1.6", "php-http/client-implementation": "^1.0", "php-http/discovery": "^1.2", "php-http/httplug": "^1.1", diff --git a/lib/Gitlab/HttpClient/Builder.php b/lib/Gitlab/HttpClient/Builder.php index 15be1ff12..8c6f586eb 100644 --- a/lib/Gitlab/HttpClient/Builder.php +++ b/lib/Gitlab/HttpClient/Builder.php @@ -5,6 +5,7 @@ use Http\Client\Common\HttpMethodsClient; use Http\Client\Common\Plugin; use Http\Client\Common\PluginClient; +use Http\Client\Common\PluginClientFactory; use Http\Client\HttpClient; use Http\Discovery\HttpClientDiscovery; use Http\Discovery\MessageFactoryDiscovery; @@ -81,7 +82,7 @@ public function getHttpClient() $this->httpClientModified = false; $this->pluginClient = new HttpMethodsClient( - new PluginClient($this->httpClient, $this->plugins), + (new PluginClientFactory())->createClient($this->httpClient, $this->plugins), $this->requestFactory ); }