Total Complexity | 4 |
Total Lines | 40 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
15 | class EntityID |
||
16 | { |
||
17 | /** |
||
18 | * @param class-string<T> $className |
||
19 | */ |
||
20 | 6 | public function __construct( |
|
21 | private readonly EntityManager $entityManager, |
||
22 | /** |
||
23 | * The entity class name. |
||
24 | */ |
||
25 | private readonly string $className, |
||
26 | /** |
||
27 | * The entity id. |
||
28 | */ |
||
29 | private readonly ?string $id |
||
30 | ) { |
||
31 | } |
||
32 | |||
33 | /** |
||
34 | * Get the ID. |
||
35 | */ |
||
36 | 2 | public function getId(): ?string |
|
37 | { |
||
38 | 2 | return $this->id; |
|
39 | } |
||
40 | |||
41 | /** |
||
42 | * Get the entity from DB. |
||
43 | * |
||
44 | * @return T entity |
||
1 ignored issue
–
show
|
|||
45 | */ |
||
46 | 4 | public function getEntity(): object |
|
55 | } |
||
56 | } |
||
57 |
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