From 1aaeda2e1392a8c154bd7754ddd2ab6bd0051681 Mon Sep 17 00:00:00 2001 From: kenjis Date: Sat, 23 Sep 2023 13:49:19 +0900 Subject: [PATCH] fix: bug that spark does not show error message --- system/CLI/Console.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/system/CLI/Console.php b/system/CLI/Console.php index 0ea7eae22c7f..16e5df831efc 100644 --- a/system/CLI/Console.php +++ b/system/CLI/Console.php @@ -12,6 +12,7 @@ namespace CodeIgniter\CLI; use CodeIgniter\CodeIgniter; +use Config\App; use Config\Services; use Exception; @@ -31,6 +32,10 @@ class Console */ public function run() { + // Create CLIRequest + $appConfig = config(App::class); + Services::createRequest($appConfig, true); + $runner = Services::commands(); $params = array_merge(CLI::getSegments(), CLI::getOptions()); $params = $this->parseParamsForHelpOption($params);