Upgrade to 3.8.0

This commit is contained in:
Bastian Allgeier
2022-10-06 10:11:54 +02:00
parent a9ed4e45ca
commit 7d168aae58
332 changed files with 26337 additions and 21977 deletions

View File

@@ -2,6 +2,7 @@
namespace Kirby\Form;
use Closure;
use Exception;
use Kirby\Exception\InvalidArgumentException;
use Kirby\Toolkit\A;
@@ -86,7 +87,7 @@ class Field extends Component
{
if (
isset($this->options['api']) === true &&
is_a($this->options['api'], 'Closure') === true
$this->options['api'] instanceof Closure
) {
return $this->options['api']->call($this);
}
@@ -112,7 +113,7 @@ class Field extends Component
return null;
}
if (is_a($save, 'Closure') === true) {
if ($save instanceof Closure) {
return $save->call($this, $value);
}
@@ -472,7 +473,7 @@ class Field extends Component
continue;
}
if (is_a($validation, 'Closure') === true) {
if ($validation instanceof Closure) {
try {
$validation->call($this, $this->value());
} catch (Exception $e) {