diff --git a/controllers/class.Login.php b/controllers/class.Login.php index 5b4899d44..5fecff96b 100644 --- a/controllers/class.Login.php +++ b/controllers/class.Login.php @@ -232,7 +232,8 @@ class SeedDMS_Controller_Login extends SeedDMS_Controller_Common { } } - $user = $authenticator->authenticate($login, $pwd); + if(!is_object($user)) + $user = $authenticator->authenticate($login, $pwd); if(0) { /* Authenticate against LDAP server {{{ */ diff --git a/inc/inc.ClassControllerCommon.php b/inc/inc.ClassControllerCommon.php index 2421ff061..f53946b02 100644 --- a/inc/inc.ClassControllerCommon.php +++ b/inc/inc.ClassControllerCommon.php @@ -75,7 +75,7 @@ class SeedDMS_Controller_Common { if(method_exists($this, $action)) { $refl = new ReflectionMethod($this, $action); if($refl->isPublic()) - return $this->{$action}(); + $ret = $this->{$action}(); else { echo "Action '".$action."' not public"; return false; @@ -85,11 +85,12 @@ class SeedDMS_Controller_Common { return false; } } else - return $this->run(); + $ret = $this->run(); } else { return false; } $this->callHook('postRun', get_class($this), $action ? $action : 'run'); + return $ret; } public function setParams($params) {