Conditions | 1 |
Paths | 1 |
Total Lines | 16 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 8 |
CRAP Score | 1 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php declare(strict_types=1); |
||
24 | 23 | public function build(array $parameters, ?Doc $methodDocBlock, UseStatements $useStatements): array |
|
25 | { |
||
26 | 23 | return array_map(function (Param $parameter) use ($methodDocBlock, $useStatements): Parameter { |
|
27 | /** @var \PhpParser\Node\Expr\Variable $parsedParameter Since the parser throws error by default */ |
||
28 | 20 | $parsedParameter = $parameter->var; |
|
29 | |||
30 | /** @var string $parameterName Since it's a parameter not a variable */ |
||
31 | 20 | $parameterName = $parsedParameter->name; |
|
32 | |||
33 | 20 | $name = "\${$parameterName}"; |
|
34 | 20 | $type = $parameter->type; |
|
35 | |||
36 | 20 | $typeDeclaration = $this->typeBuilder->fromMethodParameter($type, $methodDocBlock, $name, $useStatements); |
|
37 | |||
38 | 20 | return new Parameter(new Variable($name, $typeDeclaration), $parameter->variadic, $parameter->byRef); |
|
39 | }, $parameters); |
||
40 | } |
||
42 |
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