Logic in the init method
Arnaud Limbourg <arnaud-GdXxm9JVFPlWk0Htik3J/[email protected]> Wed, 26 Oct 2005 14:14:00 +0200
| Newsgroups | gmane.comp.php.pear.liveuser |
|---|---|
| Message-ID | <[email protected]> |
Hi all,
I found an odd behaviour in the login/logout handling logic in the init method.
The following code gets executed after the logout has been called. To me this
is not very logical that you could logout to relogin immediatly with the same
call, shouldn't the condition be changed to !$this->isLoggedIn() && !$logout ?
Does anybody have any thought on this ?
Relevant code:
940 if (!$this->isLoggedIn()) {
941 if (!$this->login($handle, $passwd, $remember) &&
$this->getErrors()) {
942 return false;
943 }
944 }