Skip to content

Commit 2daf4f9

Browse files
[Process] Skip environment variables with false value in Process
1 parent aae7998 commit 2daf4f9

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Symfony/Component/Process/Process.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,9 @@ public function start(callable $callback = null/*, array $env = array()*/)
331331
} else {
332332
$envPairs = array();
333333
foreach ($env as $k => $v) {
334-
$envPairs[] = $k.'='.$v;
334+
if (false !== $v) {
335+
$envPairs[] = $k.'='.$v;
336+
}
335337
}
336338
}
337339

0 commit comments

Comments
 (0)