[FOLLOWUP][BUGFIX] Respect interfaces as well when checking class existence 23/37423/2
authorHelmut Hummel <helmut.hummel@typo3.org>
Sun, 1 Mar 2015 17:36:51 +0000 (18:36 +0100)
committerHelmut Hummel <helmut.hummel@typo3.org>
Sun, 1 Mar 2015 17:53:27 +0000 (18:53 +0100)
Add accidentally forgotten guard clause for case insensitivity.

Releases: master, 6.2
Resolves: #65434
Change-Id: I374a7201f3c5ef356883302fc0825f9a02ef0c30
Reviewed-on: http://review.typo3.org/37423
Reviewed-by: Helmut Hummel <helmut.hummel@typo3.org>
Tested-by: Helmut Hummel <helmut.hummel@typo3.org>
typo3/contrib/vendor/helhum/class-alias-loader/Classes/Composer/ClassAliasLoader.php

index 7822cf1..f394d4b 100644 (file)
@@ -100,7 +100,10 @@ class ClassAliasLoader {
         */
        public function loadClass($className) {
                if (!$this->caseSensitiveClassLoading) {
-                       $className = strtolower($className);
+                       $lowerCasedClassName = strtolower($className);
+                       if ($this->composerClassLoader->findFile($lowerCasedClassName)) {
+                               return $this->composerClassLoader->loadClass($lowerCasedClassName);
+                       }
                }
                return $this->composerClassLoader->loadClass($className);
        }