mirror of
https://github.com/danog/class-finder.git
synced 2024-12-02 09:27:48 +01:00
Fix PHP 5.3 compatibility
This commit is contained in:
parent
1428e1a0a6
commit
2f81fac230
@ -202,8 +202,9 @@ class PSR4Namespace
|
|||||||
return array_merge($carry, $arrayOfClasses);
|
return array_merge($carry, $arrayOfClasses);
|
||||||
}, array());
|
}, array());
|
||||||
|
|
||||||
$potentialClasses = array_map(function($file) use ($self) {
|
$selfNamespace = $this->namespace; // PHP 5.3 BC
|
||||||
return $self->namespace . str_replace('.php', '', $file);
|
$potentialClasses = array_map(function($file) use ($self, $selfNamespace) {
|
||||||
|
return $selfNamespace . str_replace('.php', '', $file);
|
||||||
}, $potentialClassFiles);
|
}, $potentialClassFiles);
|
||||||
|
|
||||||
return array_filter($potentialClasses, function($potentialClass) {
|
return array_filter($potentialClasses, function($potentialClass) {
|
||||||
|
Loading…
Reference in New Issue
Block a user