| 1 | <?php |
||
| 9 | class ChangePasswordRequest extends FormRequest |
||
| 10 | { |
||
| 11 | /** |
||
| 12 | * Determine if the user is authorized to make this request. |
||
| 13 | * |
||
| 14 | * @return bool |
||
| 15 | */ |
||
| 16 | public function authorize() |
||
| 21 | |||
| 22 | /** |
||
| 23 | * Get the validation rules that apply to the request. |
||
| 24 | * |
||
| 25 | * @return array |
||
| 26 | */ |
||
| 27 | public function rules() |
||
| 35 | |||
| 36 | /** |
||
| 37 | * Configure the validator instance. |
||
| 38 | * |
||
| 39 | * @param \Illuminate\Validation\Validator $validator |
||
| 40 | * |
||
| 41 | * @return void |
||
| 42 | */ |
||
| 43 | public function withValidator($validator) |
||
| 52 | } |
||
| 53 |
If you access a property on an interface, you most likely code against a concrete implementation of the interface.
Available Fixes
Adding an additional type check:
Changing the type hint: