1
0
Fork 0

Avoid blowing up on misconfigured autoload entries

pull/585/merge
Jordi Boggiano 2012-04-17 14:01:24 +02:00
parent e12b0e842d
commit 83b52b5b7f
1 changed files with 4 additions and 0 deletions

View File

@ -148,6 +148,10 @@ EOF;
} }
foreach ($package->getAutoload() as $type => $mapping) { foreach ($package->getAutoload() as $type => $mapping) {
// skip misconfigured packages
if (!is_array($mapping)) {
continue;
}
foreach ($mapping as $namespace => $paths) { foreach ($mapping as $namespace => $paths) {
foreach ((array) $paths as $path) { foreach ((array) $paths as $path) {
$autoloads[$type][$namespace][] = empty($installPath) ? $path : $installPath.'/'.$path; $autoloads[$type][$namespace][] = empty($installPath) ? $path : $installPath.'/'.$path;