Skip to content

Commit

Permalink
Change getenv() for $_SERVER['APP_ENV']
Browse files Browse the repository at this point in the history
  • Loading branch information
noelamaya committed Apr 28, 2021
1 parent 7cef833 commit 6429669
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Sifo/Config.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ protected function __construct( $instance_name )
include( $this->config_path . $this->configuration_files );
$this->paths_to_configs = $config;

$env_file = getenv('APP_ENV') === 'test' ? '.env.test' : '.env';
$env_file = (isset($_SERVER['APP_ENV']) && $_SERVER['APP_ENV'] === 'test') ? '.env.test' : '.env';
$dotenv = new Dotenv();

try {
Expand Down

0 comments on commit 6429669

Please sign in to comment.