1 | <?php |
||
11 | class RoleFormRequest extends FormRequest |
||
12 | { |
||
13 | use Escaper; |
||
14 | |||
15 | /** |
||
16 | * Determine if the user is authorized to make this request. |
||
17 | * |
||
18 | * @throws \Cortex\Foundation\Exceptions\GenericException |
||
19 | * |
||
20 | * @return bool |
||
21 | */ |
||
22 | public function authorize(): bool |
||
32 | |||
33 | /** |
||
34 | * Get the validation rules that apply to the request. |
||
35 | * |
||
36 | * @return array |
||
37 | */ |
||
38 | public function rules(): array |
||
42 | } |
||
43 |
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: