From 2bb4287d0f29001b5ef51edafe26e73bcadc3d6b Mon Sep 17 00:00:00 2001 From: Ben Carey Date: Wed, 29 May 2024 00:48:50 +0100 Subject: [PATCH] Fixed issue with dynamic model calls --- src/Repository.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Repository.php b/src/Repository.php index e02b52c..4ff2ce1 100644 --- a/src/Repository.php +++ b/src/Repository.php @@ -64,7 +64,7 @@ public function __construct( */ public static function __callStatic(string $method, array $arguments): mixed { - return call_user_func_array([new static, $method], ...$arguments); + return call_user_func_array([new static, $method], $arguments); } /** @@ -79,7 +79,7 @@ public function __call(string $method, array $arguments): mixed $this->applyCriteria(); $this->applyScopes(); - $result = call_user_func_array([$this->model, $method], ...$arguments); + $result = call_user_func_array([$this->model, $method], $arguments); return $this->resetAndReturn($result); }