Skip to content

Commit

Permalink
fixed expects array error
Browse files Browse the repository at this point in the history
  • Loading branch information
hiqsol committed Oct 17, 2017
1 parent 05fff11 commit 2b9795d
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/Builder.php
Original file line number Diff line number Diff line change
Expand Up @@ -172,10 +172,12 @@ public function buildConfig($name, array $configs, $defines = [])
protected function pushEnvVars($vars)
{
$env = $this->vars['dotenv'];
foreach (array_keys($vars) as $key) {
$envKey = strtoupper(strtr($key, '.', '_'));
if (isset($env[$envKey])) {
$vars[$key] = $env[$envKey];
if (!empty($vars)) {
foreach (array_keys($vars) as $key) {
$envKey = strtoupper(strtr($key, '.', '_'));
if (isset($env[$envKey])) {
$vars[$key] = $env[$envKey];
}
}
}

Expand Down

0 comments on commit 2b9795d

Please sign in to comment.