Skip to content

Commit df25755

Browse files
authored
Merge pull request #3 from JYPDWhite/master
added a isset check around $argv
2 parents 540f96c + ca2aeb4 commit df25755

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

functions.php

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,12 @@
66
$quiet = false;
77

88
//Check passed options
9-
foreach ($argv as $option) {
10-
if ($option === "--quiet") {
11-
$quiet = true;
12-
}
9+
if(isset($argv)){
10+
foreach ($argv as $option) {
11+
if ($option === "--quiet") {
12+
$quiet = true;
13+
}
14+
}
1315
}
1416

1517
const SUCCESS = 'success';

0 commit comments

Comments
 (0)