Skip to content

Commit a6794a3

Browse files
committed
:octocat:
1 parent 70fa783 commit a6794a3

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

README.md

+10-1
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ You can then invoke the multi request client - the `MultiResponseHandlerInterfac
130130
`HTTPOptions` and `LoggerInterface` are optional:
131131

132132
```php
133-
$options = new HTTPOptions;
133+
$options = new HTTPOptions;
134134
$options->ca_info = '/path/to/cacert.pem';
135135
$options->user_agent = 'my cool user agent 1.0';
136136
$options->sleep = 750000; // microseconds, see usleep()
@@ -154,6 +154,15 @@ $multiClient->process();
154154
The `URLExtractor` wraps a PSR-18 `ClientInterface` to extract and follow shortened URLs to their original location.
155155

156156
```php
157+
$options = new HTTPOptions;
158+
$options->user_agent = 'my cool user agent 1.0';
159+
$options->ssl_verifypeer = false;
160+
$options->curl_options = [
161+
CURLOPT_FOLLOWLOCATION => false,
162+
CURLOPT_MAXREDIRS => 25,
163+
];
164+
165+
$httpClient = new CurlClient($responseFactory, $options, $logger);
157166
$urlExtractor = new URLExtractor($httpClient, $responseFactory);
158167

159168
$request = $factory->createRequest('GET', 'https://t.co/ZSS6nVOcVp');

0 commit comments

Comments
 (0)