Autoload fixes

This commit is contained in:
Taras Machyshyn
2022-04-08 16:28:12 +03:00
parent 58a89146c9
commit 31a507cd4a
@@ -214,9 +214,14 @@ class NamespaceLoader
foreach ($itemData as $prefix => $path) {
if (!$skipVendorNamespaces) {
$vendorNamespaces = $this->getVendorNamespaces($path);
$vendorPaths = is_array($path) ? $path : (array) $path;
$this->addListToClassLoader($vendorNamespaces, true);
foreach ($vendorPaths as $vendorPath) {
$this->addListToClassLoader(
$this->getVendorNamespaces($vendorPath),
true
);
}
}
if ($this->hasNamespace($type, $prefix)) {