[FORM] Add Form::isRequired
This commit is contained in:
parent
6adb527fe0
commit
1e911f1ba4
@ -52,4 +52,9 @@ abstract class Form
|
|||||||
}
|
}
|
||||||
return $fb->getForm();
|
return $fb->getForm();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static function isRequired(array $form, string $field): bool
|
||||||
|
{
|
||||||
|
return $form[$field][2]['required'] ?? true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user