1 | <?php |
||
8 | class AliasResolver |
||
9 | { |
||
10 | /** |
||
11 | * @var static |
||
12 | */ |
||
13 | protected static $instance; |
||
14 | |||
15 | /** |
||
16 | * @param string $apppath |
||
17 | * @param array $addons |
||
18 | * @param array $aliases |
||
19 | */ |
||
20 | 2 | public static function register($apppath, array $addons, array $aliases) |
|
26 | |||
27 | /** |
||
28 | */ |
||
29 | 2 | public static function unregister() |
|
35 | |||
36 | /** |
||
37 | * @var array |
||
38 | */ |
||
39 | protected $addons; |
||
40 | |||
41 | /** |
||
42 | * @var array |
||
43 | */ |
||
44 | protected $globalClassAliases; |
||
45 | |||
46 | /** |
||
47 | * The constructor. |
||
48 | * |
||
49 | * @param string $apppath |
||
50 | * @param array $addons |
||
51 | * @param array $aliases |
||
52 | */ |
||
53 | 3 | public function __construct($apppath, array $addons, array $aliases) |
|
58 | |||
59 | /** |
||
60 | * Make addon instance for application namespace. |
||
61 | * |
||
62 | * @param string $path |
||
63 | * |
||
64 | * @return static |
||
65 | */ |
||
66 | 3 | protected function makeAppAddon($path) |
|
74 | |||
75 | /** |
||
76 | * @param string $className |
||
77 | * |
||
78 | * @return bool |
||
79 | */ |
||
80 | 1 | public function load($className) |
|
126 | |||
127 | /** |
||
128 | * Get the application namespace. |
||
129 | * |
||
130 | * @return string |
||
131 | */ |
||
132 | 3 | protected function getAppNamespace() |
|
136 | } |
||
137 |
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: