Skip to content

Commit

Permalink
Use call_user_func
Browse files Browse the repository at this point in the history
  • Loading branch information
aschempp committed Sep 3, 2024
1 parent 9e83386 commit c0ac3f2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Form/Form.php
Original file line number Diff line number Diff line change
Expand Up @@ -737,7 +737,7 @@ public function validate(): bool

foreach ($this->widgets as $fieldName => $widget) {
if (null !== $this->inputCallback && method_exists($widget, 'setInputCallback')) {
$widget->setInputCallback(fn () => ${$this->inputCallback}($fieldName, $widget));
$widget->setInputCallback(fn () => call_user_func($this->inputCallback, $fieldName, $widget));
}

$widget->validate();
Expand Down

0 comments on commit c0ac3f2

Please sign in to comment.