From d530572182f24e28131b87b5237ca11e7800d76d Mon Sep 17 00:00:00 2001 From: Rick Kuilman Date: Thu, 8 Jul 2021 17:02:31 +0200 Subject: [PATCH] Added compatibility for PHP 7.2.x Added compatibility for PHP 7.2.x --- src/HasTemporaryFields.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/HasTemporaryFields.php b/src/HasTemporaryFields.php index 73aa70a..004e5a3 100644 --- a/src/HasTemporaryFields.php +++ b/src/HasTemporaryFields.php @@ -8,6 +8,8 @@ trait HasTemporaryFields { protected static function fillFields(NovaRequest $request, $model, $fields) { - return parent::fillFields($request, $model, $fields->reject(fn ($field) => $field->meta['_temp'] ?? false)); + return parent::fillFields($request, $model, $fields->reject(function ($field) { + return $field->meta['_temp'] ?? false; + })); } -} \ No newline at end of file +}