| 1 | <?php |
||
| 12 | class StatsModel extends AbstractDatabaseModel |
||
| 13 | { |
||
| 14 | /** |
||
| 15 | * Loads the statistics data from the database. |
||
| 16 | * |
||
| 17 | * @param string $column A single column to filter on |
||
| 18 | * |
||
| 19 | * @return \stdClass[] Array of data objects. |
||
| 20 | * |
||
| 21 | * @since 1.0 |
||
| 22 | * @throws \InvalidArgumentException |
||
| 23 | */ |
||
| 24 | 3 | public function getItems($column = null) |
|
| 50 | |||
| 51 | /** |
||
| 52 | * Saves the given data. |
||
| 53 | * |
||
| 54 | * @param \stdClass $data Data object to save. |
||
| 55 | * |
||
| 56 | * @return void |
||
| 57 | * |
||
| 58 | * @since 1.0 |
||
| 59 | */ |
||
| 60 | 2 | public function save($data) |
|
| 84 | } |
||
| 85 |
It seems like the type of the argument is not accepted by the function/method which you are calling.
In some cases, in particular if PHP’s automatic type-juggling kicks in this might be fine. In other cases, however this might be a bug.
We suggest to add an explicit type cast like in the following example: