Fix cleared custom validation
This commit is contained in:
parent
d302b79461
commit
7b97705c5b
|
|
@ -33,11 +33,11 @@ class CustomFieldValidationRule implements ValidationRule
|
|||
*/
|
||||
public function passes($attribute, $value)
|
||||
{
|
||||
if (!($this->validation['error_conditions']['conditions'] ?? null) || is_null(
|
||||
$this->validation['error_conditions']['conditions'] ?? null
|
||||
)) {
|
||||
$logicConditions = $this->validation['error_conditions']['conditions'] ?? null;
|
||||
if (empty($logicConditions) || empty($logicConditions['children'] ?? [])) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return FormLogicConditionChecker::conditionsMet(
|
||||
$this->validation['error_conditions']['conditions'],
|
||||
$this->formData
|
||||
|
|
|
|||
Loading…
Reference in New Issue