| Conditions | 3 |
| Paths | 3 |
| Total Lines | 13 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 23 | public function boot(DirectoriesInterface $dirs, EnvironmentInterface $env) |
||
| 24 | { |
||
| 25 | $dotenvPath = $env->get('DOTENV_PATH', $dirs->get('root') . '.env'); |
||
| 26 | |||
| 27 | if (!file_exists($dotenvPath)) { |
||
| 28 | return; |
||
| 29 | } |
||
| 30 | |||
| 31 | $path = dirname($dotenvPath); |
||
| 32 | $file = basename($dotenvPath); |
||
| 33 | |||
| 34 | foreach (Dotenv::create($path, $file)->load() as $key => $value) { |
||
|
|
|||
| 35 | $env->set($key, $value); |
||
| 36 | } |
||
| 38 | } |