Skip to content

Commit c3095ca

Browse files
glaubinixradutopala
authored andcommitted
Client: allow usage of options (#173)
1 parent 49d86fd commit c3095ca

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

lib/Gitlab/Client.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,9 +73,14 @@ class Client
7373
*
7474
* @param string $baseUrl
7575
* @param null|ClientInterface $httpClient Buzz client
76+
* @param array $options
7677
*/
77-
public function __construct($baseUrl, ClientInterface $httpClient = null)
78+
public function __construct($baseUrl, ClientInterface $httpClient = null, array $options = array())
7879
{
80+
foreach ($options as $name => $value) {
81+
$this->setOption($name, $value);
82+
}
83+
7984
$httpClient = $httpClient ?: new Curl();
8085
$httpClient->setTimeout($this->options['timeout']);
8186
$httpClient->setVerifyPeer(false);

0 commit comments

Comments
 (0)