From a28b4bcd7cb66c33aaa16686c0053958dc076d53 Mon Sep 17 00:00:00 2001 From: Pooya Parsa Dadashi Date: Tue, 1 Oct 2024 17:13:43 +0330 Subject: [PATCH] refactor: remove unnecessary `is_countable()` check in `getMethodParams` --- system/Router/RouteCollection.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/system/Router/RouteCollection.php b/system/Router/RouteCollection.php index 8fba39dc03be..231711c48aac 100644 --- a/system/Router/RouteCollection.php +++ b/system/Router/RouteCollection.php @@ -1604,7 +1604,7 @@ private function processArrayCallableSyntax(string $from, array $to): string private function getMethodParams(string $from): string { preg_match_all('/\(.+?\)/', $from, $matches); - $count = is_countable($matches[0]) ? count($matches[0]) : 0; + $count = count($matches[0]); $params = '';