Skip to content

Commit

Permalink
[Finder] Only use GLOB_BRACE when available
Browse files Browse the repository at this point in the history
  • Loading branch information
dosten authored and fabpot committed May 1, 2015
1 parent 1439da4 commit 7632d27
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Symfony/Component/Finder/Finder.php
Expand Up @@ -671,7 +671,7 @@ public function in($dirs)
foreach ((array) $dirs as $dir) {
if (is_dir($dir)) {
$resolvedDirs[] = $dir;
} elseif ($glob = glob($dir, GLOB_BRACE | GLOB_ONLYDIR)) {
} elseif ($glob = glob($dir, (defined('GLOB_BRACE') ? GLOB_BRACE : 0) | GLOB_ONLYDIR)) {
$resolvedDirs = array_merge($resolvedDirs, $glob);
} else {
throw new \InvalidArgumentException(sprintf('The "%s" directory does not exist.', $dir));
Expand Down

0 comments on commit 7632d27

Please sign in to comment.