diff options
author | robocoder <anthon.pang@gmail.com> | 2009-06-16 20:44:43 +0400 |
---|---|---|
committer | robocoder <anthon.pang@gmail.com> | 2009-06-16 20:44:43 +0400 |
commit | 7040ddc4e2e4bc741362d3a8ee1a42e906a8c287 (patch) | |
tree | f9dd4ee14214dafc70dbed04d106220960766760 /core | |
parent | 2224157f543c7c05ff100f46c091680a6dd7c823 (diff) |
refs #803 - Auth is loaded by piwik.php?
git-svn-id: http://dev.piwik.org/svn/trunk@1233 59fd770c-687e-43c8-a1e3-f5a4ff64c105
Diffstat (limited to 'core')
-rw-r--r-- | core/Auth.php | 2 | ||||
-rw-r--r-- | core/Loader.php | 5 |
2 files changed, 5 insertions, 2 deletions
diff --git a/core/Auth.php b/core/Auth.php index 315a0fb341..526fcb0b10 100644 --- a/core/Auth.php +++ b/core/Auth.php @@ -9,6 +9,8 @@ * @package Piwik */ +require "Zend/Auth/Result.php"; + interface Piwik_Auth { /** * Authentication module's name, e.g., "Login" diff --git a/core/Loader.php b/core/Loader.php index 3745e8e144..97f5decd46 100644 --- a/core/Loader.php +++ b/core/Loader.php @@ -42,8 +42,8 @@ class Piwik_Loader $path = PIWIK_INCLUDE_PATH . self::$dirs[$i] . $classPath . '.php'; if(file_exists($path)) { - include_once($path); - if(class_exists($class, false)) + require_once($path); + if(class_exists($class, false) || interface_exists($class, false)) { return; } @@ -54,6 +54,7 @@ class Piwik_Loader $lastSlash = strrpos($classPath, '/'); $classPath = ($lastSlash === false) ? '' : substr($classPath, 0, $lastSlash); } + throw new Exception("$class could not be autoloaded."); } } |