❇️ Inclut le client dans la librairie
This commit is contained in:
@@ -18,9 +18,24 @@ class Account
|
||||
* @param Client $client
|
||||
* @param Config $config
|
||||
*/
|
||||
public function __construct(Client $client, Config $config)
|
||||
public function __construct(Config $config)
|
||||
{
|
||||
$this->client = $client;
|
||||
$this->client = new \Goutte\Client();
|
||||
$this->client->setClient(
|
||||
new \GuzzleHttp\Client([
|
||||
'timeout' => 90,
|
||||
'verify' => false,
|
||||
'curl' => [
|
||||
CURLOPT_TIMEOUT => 60,
|
||||
CURLOPT_TIMEOUT_MS => 60,
|
||||
CURLOPT_CONNECTTIMEOUT => 60,
|
||||
],
|
||||
'headers' => [
|
||||
'User-Agent' => 'Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:39.0) Gecko/20100101 Firefox/39.0',
|
||||
],
|
||||
])
|
||||
);
|
||||
$this->client->setMaxRedirects(10);
|
||||
$this->config = $config;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user