1
0
Fork 0
mirror of https://github.com/composer/composer synced 2025-05-10 09:02:59 +00:00

Throw a RuntimeException when glob braces are used but not supported by the OS

This commit is contained in:
Markus Staab 2018-07-18 16:38:44 +02:00 committed by GitHub
parent e89d16c47d
commit 70a1a6e510
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -178,6 +178,8 @@ class PathRepository extends ArrayRepository implements ConfigurableRepositoryIn
if (defined('GLOB_BRACE')) {
$flags |= GLOB_BRACE;
} elseif (strpos($this->url, '{') !== false || strpos($this->url, '}') !== false) {
throw new \RuntimeException('The operating system does not support GLOB_BRACE which is required for the url '. $this->url);
}
// Ensure environment-specific path separators are normalized to URL separators