|
1 | 1 | <?php |
2 | 2 |
|
3 | | -useSymfony\Component\Dotenv\Dotenv; |
| 3 | +#use Symfony\Component\Dotenv\Dotenv; |
4 | 4 |
|
5 | 5 | requiredirname(__DIR__).'/vendor/autoload.php'; |
6 | 6 |
|
7 | 7 | if (!array_key_exists('APP_ENV',$_SERVER)) { |
8 | 8 | $_SERVER['APP_ENV'] =$_ENV['APP_ENV'] ??null; |
9 | 9 | } |
10 | 10 |
|
11 | | -if ('prod' !==$_SERVER['APP_ENV']) { |
| 11 | +/*if ('prod' !== $_SERVER['APP_ENV']) { |
12 | 12 | if (!class_exists(Dotenv::class)) { |
13 | 13 | throw new RuntimeException('The "APP_ENV" environment variable is not set to "prod". Please run "composer require symfony/dotenv" to load the ".env" files configuring the application.'); |
14 | 14 | } |
15 | 15 |
|
16 | 16 | (new Dotenv())->loadEnv(dirname(__DIR__).'/.env'); |
17 | | -} |
| 17 | +}*/ |
18 | 18 |
|
19 | 19 | $_SERVER['APP_ENV'] =$_ENV['APP_ENV'] =$_SERVER['APP_ENV'] ?:$_ENV['APP_ENV'] ?:'dev'; |
20 | 20 | $_SERVER['APP_DEBUG'] =$_SERVER['APP_DEBUG'] ??$_ENV['APP_DEBUG'] ??'prod' !==$_SERVER['APP_ENV']; |
|