mirror of
https://github.com/MarijnDoeve/TijdVoorDeTest.git
synced 2026-03-06 04:44:19 +01:00
WIP 3-3
This commit is contained in:
@@ -1,7 +1,14 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
use App\Kernel;
|
||||
|
||||
require_once dirname(__DIR__).'/vendor/autoload_runtime.php';
|
||||
|
||||
return fn (array $context): \App\Kernel => new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']);
|
||||
return static function (array $context): Kernel {
|
||||
$appEnv = !empty($context['APP_ENV']) ? (string) $context['APP_ENV'] : 'prod';
|
||||
$appDebug = !empty($context['APP_DEBUG']) ? filter_var($context['APP_DEBUG'], \FILTER_VALIDATE_BOOL) : 'prod' !== $appEnv;
|
||||
|
||||
return new Kernel($appEnv, $appDebug);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user