diff --git a/src/Config.php b/src/Config.php index 5c3a60e..6c73702 100644 --- a/src/Config.php +++ b/src/Config.php @@ -132,6 +132,11 @@ public function __construct(array $config = []) { $c )); } + + // if client hasn't been constructed, construct. + if (null === $this->HttpClient) { + $this->HttpClient = new Client(); + } } /** @@ -150,7 +155,6 @@ private static function getDefaultConfig() { $conf = [ 'Address' => '127.0.0.1:8500', 'Scheme' => 'http', - 'HttpClient' => new Client(), ]; // parse env vars