Added a more strict way to handle valid and expected env vars

This commit is contained in:
Alejandro Celaya
2022-01-20 20:16:37 +01:00
parent 07d24f70e1
commit 747dac531d
16 changed files with 228 additions and 69 deletions

View File

@@ -21,7 +21,7 @@ $isTestEnv = env('APP_ENV') === 'test';
return (new ConfigAggregator\ConfigAggregator([
! $isTestEnv
? new EnvVarLoaderProvider('config/params/generated_config.php')
? new EnvVarLoaderProvider('config/params/generated_config.php', Core\Config\EnvVars::cases())
: new ConfigAggregator\ArrayProvider([]),
Mezzio\ConfigProvider::class,
Mezzio\Router\ConfigProvider::class,