Conditions | 4 |
Paths | 3 |
Total Lines | 16 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 4.0312 |
Changes | 0 |
1 | <?php declare(strict_types=1); |
||
34 | 2 | public function map(string $path): Mapper |
|
35 | { |
||
36 | 2 | foreach (listClassesInDirectory($path) as $class) { |
|
37 | 2 | $jobs = self::getJobsFromCommand($class); |
|
38 | |||
39 | 2 | if (\count($jobs) === 0) { |
|
40 | continue; |
||
41 | } |
||
42 | |||
43 | 2 | foreach ($jobs as $job) { |
|
44 | 2 | $this->map[$job] = $class; |
|
45 | } |
||
46 | } |
||
47 | |||
48 | 2 | return $this; |
|
49 | } |
||
50 | |||
90 |
This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function.
Consider the following example. The parameter
$italy
is not defined by the methodfinale(...)
.The most likely cause is that the parameter was removed, but the annotation was not.