diff --git a/src/Axm.php b/src/Axm.php index 2e6b4ab..09b8b50 100644 --- a/src/Axm.php +++ b/src/Axm.php @@ -93,8 +93,8 @@ public static function is_cli(): bool */ private static function initializeEnvironment() { - // Obtain the value of AXM_ENVIRONMENT or use a default value - static::$_environment = $env = env('AXM_ENVIRONMENT', 'production'); + // Obtain the value of APP_ENVIRONMENT or use a default value + static::$_environment = $env = env('APP_ENVIRONMENT', 'production'); // Configuring environment-based error handling. if ($env === 'debug') { diff --git a/src/axm_helper.php b/src/axm_helper.php index bef8a53..332d257 100644 --- a/src/axm_helper.php +++ b/src/axm_helper.php @@ -96,7 +96,7 @@ function raxmScripts() * @param string $ext The file extension of the View template (default is '.php'). * @return void */ - function view(string $view, $params = null, bool $buffer = true, string $ext = '.php') + function view(string $view, array $params = [], bool $buffer = true, string $ext = '.php') { // Render the View template using the provided parameters. $renderedView = Axm::app()->controller->renderView($view, $params, $buffer, $ext);