1 | <?php |
||
13 | class Vasri |
||
14 | { |
||
15 | |||
16 | /** |
||
17 | * @var Builder|null |
||
18 | */ |
||
19 | private static $builder = null; |
||
20 | |||
21 | /** |
||
22 | * Vasri constructor. |
||
23 | */ |
||
24 | public function __construct() |
||
28 | |||
29 | /** |
||
30 | * @param string $type |
||
31 | * @param string $path |
||
32 | * @param bool $enable_versioning |
||
33 | * @param bool $enable_sri |
||
34 | * |
||
35 | * @return string |
||
36 | * @throws Exception |
||
37 | */ |
||
38 | public static function vasri( |
||
60 | |||
61 | /** |
||
62 | * @param string $path |
||
63 | * |
||
64 | * @return string |
||
65 | */ |
||
66 | private static function addVersioning(string $path): string |
||
70 | |||
71 | /** |
||
72 | * @param string $path |
||
73 | * @param string $hash |
||
74 | * |
||
75 | * @return string |
||
76 | * @throws Exception |
||
77 | */ |
||
78 | private static function addSRI(string $path, string $hash = 'sha384'): string |
||
82 | |||
83 | /** |
||
84 | * @return Builder |
||
85 | */ |
||
86 | private static function loadBuilder(): Builder |
||
90 | |||
91 | /** |
||
92 | * @param string $type |
||
93 | * @param string $path |
||
94 | * @param string $enable_versioning |
||
95 | * |
||
96 | * @return string |
||
97 | * @throws Exception |
||
98 | */ |
||
99 | private static function addAttribute(string $type, string $path, string $enable_versioning) |
||
115 | |||
116 | /** |
||
117 | * |
||
118 | * @param string $path |
||
119 | * |
||
120 | * @return bool |
||
121 | */ |
||
122 | private static function checkPath(string $path): bool |
||
126 | |||
127 | } |
||
128 |
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: