1 | <?php |
||
8 | class ModelCleanedEvent extends Event |
||
9 | { |
||
10 | |||
11 | public $modelName; |
||
12 | public $numberOfDeletedRecords; |
||
13 | |||
14 | /** |
||
15 | * Create a new event instance. |
||
16 | * |
||
17 | * @param string $modelName |
||
18 | * @param int $deletedRecords |
||
|
|||
19 | * @return void |
||
20 | */ |
||
21 | public function __construct(string $modelName, int $numberOfDeletedRecords) |
||
26 | } |
This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function. It has, however, found a similar but not annotated parameter which might be a good fit.
Consider the following example. The parameter
$ireland
is not defined by the methodfinale(...)
.The most likely cause is that the parameter was changed, but the annotation was not.