Skip to content
This repository was archived by the owner on Jan 31, 2020. It is now read-only.

Commit 2526103

Browse files
José Moreiraweierophinney
José Moreira
authored andcommitted
Check if GLOB_BRACE is defined before using it #58
This commit refers to the issue #58 and fixes an exception that was arising up on systems based on MUSL (and probably other UNIX based rather than GNU Linux) ``` [Exception] Notice: Use of undefined constant GLOB_BRACE - assumed 'GLOB_BRACE' in /magento/vendor/zendframework/zend-stdlib/src/Glob.php on line 64 ```
1 parent 4499760 commit 2526103

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Glob.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ protected static function systemGlob($pattern, $flags)
6161
self::GLOB_NOSORT => GLOB_NOSORT,
6262
self::GLOB_NOCHECK => GLOB_NOCHECK,
6363
self::GLOB_NOESCAPE => GLOB_NOESCAPE,
64-
self::GLOB_BRACE => GLOB_BRACE,
64+
self::GLOB_BRACE => defined('GLOB_BRACE') ? GLOB_BRACE : 0,
6565
self::GLOB_ONLYDIR => GLOB_ONLYDIR,
6666
self::GLOB_ERR => GLOB_ERR,
6767
];

0 commit comments

Comments
 (0)