Update autoloader files

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
This commit is contained in:
Roeland Jago Douma 2021-03-02 16:36:21 +01:00
parent 2afa1c5739
commit 19e2136963
26 changed files with 104 additions and 52 deletions

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);

View File

@ -311,8 +311,10 @@ class ClassLoader
spl_autoload_register(array($this, 'loadClass'), true, $prepend); spl_autoload_register(array($this, 'loadClass'), true, $prepend);
if (null === $this->vendorDir) { if (null === $this->vendorDir) {
//no-op return;
} elseif ($prepend) { }
if ($prepend) {
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
} else { } else {
unset(self::$registeredLoaders[$this->vendorDir]); unset(self::$registeredLoaders[$this->vendorDir]);