| 1 | <?php |
||
| 13 | class ValuelistService |
||
| 14 | { |
||
| 15 | private static $instance; |
||
| 16 | /** |
||
| 17 | * @var Storage |
||
| 18 | */ |
||
| 19 | protected $storage; |
||
| 20 | |||
| 21 | /** |
||
| 22 | * FileService constructor. |
||
| 23 | */ |
||
| 24 | protected function __construct() |
||
| 26 | |||
| 27 | /** |
||
| 28 | * @return ValuelistService |
||
| 29 | */ |
||
| 30 | public static function getInstance() |
||
| 37 | |||
| 38 | /** |
||
| 39 | * @param $slug |
||
| 40 | * @return Valuelist |
||
| 41 | */ |
||
| 42 | public static function get($slug) |
||
| 49 | |||
| 50 | /** |
||
| 51 | * @param Storage $storage |
||
| 52 | */ |
||
| 53 | public function init(Storage $storage) |
||
| 57 | } |
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: