Bläddra i källkod

[ClassLoader] fixed usage of trait_exists()

Fabien Potencier 13 år sedan
förälder
incheckning
cf4a91e923
1 ändrade filer med 1 tillägg och 1 borttagningar
  1. 1 1
      src/Symfony/Component/ClassLoader/DebugUniversalClassLoader.php

+ 1 - 1
src/Symfony/Component/ClassLoader/DebugUniversalClassLoader.php

@@ -54,7 +54,7 @@ class DebugUniversalClassLoader extends UniversalClassLoader
         if ($file = $this->findFile($class)) {
             require $file;
 
-            if (!class_exists($class, false) && !interface_exists($class, false) && (!function_exists('trait_exists') || !trait_exists($class))) {
+            if (!class_exists($class, false) && !interface_exists($class, false) && (!function_exists('trait_exists') || !trait_exists($class, false))) {
                 throw new \RuntimeException(sprintf('The autoloader expected class "%s" to be defined in file "%s". The file was found but the class was not in it, the class name or namespace probably has a typo.', $class, $file));
             }
         }