| Conditions | 4 |
| Paths | 2 |
| Total Lines | 7 |
| Code Lines | 3 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 20 | public function __construct(HttpClientInterface $httpClient = null) |
||
| 21 | { |
||
| 22 | if (null === $httpClient && !\class_exists(HttpClient::class)) { |
||
| 23 | throw new \LogicException(\sprintf('Symfony HttpClient is required to use the "%s" extension. Install with "composer require symfony/http-client".', PingExtension::class)); |
||
| 24 | } |
||
| 25 | |||
| 26 | $this->httpClient = $httpClient ?: HttpClient::create(); |
||
| 27 | } |
||
| 46 |