| Conditions | 1 |
| Paths | 1 |
| Total Lines | 14 |
| Code Lines | 9 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php |
||
| 14 | public function register(DiInterface $container) |
||
| 15 | { |
||
| 16 | $config = $container->getShared('config'); |
||
| 17 | |||
| 18 | $container->setShared( |
||
| 19 | 'elastic', |
||
| 20 | function () use ($config) { |
||
| 21 | $hosts = $config->elasticSearch->hosts->toArray(); |
||
| 22 | |||
| 23 | $client = ClientBuilder::create() |
||
| 24 | ->setHosts($hosts) |
||
| 25 | ->build(); |
||
| 26 | |||
| 27 | return $client; |
||
| 28 | } |
||
| 32 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths