Closed
Description
Laravel Version
10.4.1
PHP Version
8.1.2
Database Driver & Version
No response
Description
When using "RequiredIf" validation rule that is dependant on another boolean field, if the boolean field gets a non empty array as input, an ErrorException is thrown when trying to get the displayable value of the boolean field.
Steps To Reproduce
$validator = \Illuminate\Support\Facades\Validator::make([
'is_customer' => ['test'],
'fullname' => null
], [
'is_customer' => 'required|boolean',
'fullname' => 'required_if:is_customer,true'
]);
$validator->fails(); // <= ErrorException