Total Complexity | 8 |
Total Lines | 61 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
16 | final class Instance implements DependencyInterface |
||
17 | { |
||
18 | /** @var mixed */ |
||
19 | public $value; |
||
20 | |||
21 | /** |
||
22 | * @param mixed $value |
||
23 | */ |
||
24 | public function __construct($value) |
||
25 | { |
||
26 | $this->value = $value; |
||
27 | } |
||
28 | |||
29 | public function __toString(): string |
||
30 | { |
||
31 | if (is_scalar($this->value)) { |
||
32 | return sprintf( |
||
33 | '(%s) %s', |
||
34 | gettype($this->value), |
||
35 | (string) $this->value |
||
36 | ); |
||
37 | } |
||
38 | |||
39 | if (is_object($this->value)) { |
||
40 | return '(object) ' . get_class($this->value); |
||
41 | } |
||
42 | |||
43 | return '(' . gettype($this->value) . ')'; |
||
44 | } |
||
45 | |||
46 | /** |
||
47 | * {@inheritdoc} |
||
48 | */ |
||
49 | public function register(array &$container, Bind $bind): void |
||
53 | } |
||
54 | |||
55 | /** |
||
56 | * {@inheritdoc} |
||
57 | */ |
||
58 | public function inject(Container $container) |
||
61 | } |
||
62 | |||
63 | /** |
||
64 | * {@inheritdoc} |
||
65 | * |
||
66 | * @codeCoverageIgnore |
||
67 | */ |
||
68 | public function setScope($scope): void |
||
70 | } |
||
71 | |||
72 | public function accept(VisitorInterface $visitor): string |
||
77 | } |
||
78 | } |
||
79 |
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