From 5633691e070e09187ef6e2e243fd7c23bc57f73f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A1bio=20Assun=C3=A7=C3=A3o?= Date: Wed, 31 May 2023 19:30:11 -0300 Subject: [PATCH] Small fixes --- src/Theme.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Theme.php b/src/Theme.php index 189c972..4f292fd 100644 --- a/src/Theme.php +++ b/src/Theme.php @@ -209,7 +209,7 @@ public function getNamespace(string $path = null): string return "Themes\\$vendor\\$name\\" . $path; } - public function getInstance(string $path) + public function getInstance(string $path, ...$params) { if (! $this->enabled()) { $this->requireClass($path); @@ -221,7 +221,7 @@ public function getInstance(string $path) throw new Exception("Class not found: {$class}"); } - return new $class; + return new $class(...$params); } /**