| 1 | <?php | ||
| 8 | class Comment extends ActiveRecordModelExtender | ||
| 9 | { | ||
| 10 | |||
| 11 | /** | ||
| 12 | * @var string $tableName name of the database table. | ||
| 13 | */ | ||
| 14 | protected $tableName = "coffee_comments"; | ||
| 15 | |||
| 16 | /** | ||
| 17 | * Columns in the table. | ||
| 18 | * | ||
| 19 | * @var integer $id primary key auto incremented. | ||
| 20 | */ | ||
| 21 | public $id; | ||
| 22 | public $user; # question/answer/comment | ||
| 23 | public $parentId; # All posts have different ids | ||
| 24 | |||
| 25 | public $text; | ||
| 26 | |||
| 27 | public $created; | ||
| 28 | |||
| 29 | /** | ||
| 30 | * Returns post with markdown and gravatar | ||
| 31 | * @param string $sql | ||
| 32 | * @param array $param | ||
|  | |||
| 33 | * | ||
| 34 | * @return array | ||
| 35 | */ | ||
| 36 | 10 | public function getComments($sql, $params) | |
| 52 | } | ||
| 53 | 
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
$irelandis not defined by the methodfinale(...).The most likely cause is that the parameter was changed, but the annotation was not.