diff options
author | Arun Persaud <arun@nubati.net> | 2012-12-09 18:39:26 -0800 |
---|---|---|
committer | Arun Persaud <arun@nubati.net> | 2012-12-09 18:39:26 -0800 |
commit | 4681b437e331256dc70663f130ce2de57a03d099 (patch) | |
tree | ec4e7730f69142d3ed8f9f1a811ee40f384b7fa3 /include/user.php | |
parent | 92d9bfa8b94111e0684029cf1237cbc9b64728ac (diff) | |
download | e-DoKo-4681b437e331256dc70663f130ce2de57a03d099.tar.gz e-DoKo-4681b437e331256dc70663f130ce2de57a03d099.tar.bz2 e-DoKo-4681b437e331256dc70663f130ce2de57a03d099.zip |
BUGFIX: fix error when user is not logged in, but tries to access his home page
needed to test, if variables were set or not.
Diffstat (limited to 'include/user.php')
-rw-r--r-- | include/user.php | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/include/user.php b/include/user.php index d486b07..607e89d 100644 --- a/include/user.php +++ b/include/user.php @@ -101,10 +101,14 @@ else { /* normal user page */ /* verify password and email */ - $ok = 1; - $myid = DB_get_userid('email-password',$email,$password); - if(!$myid) + if(isset($email, $password)) + { + $myid = DB_get_userid('email-password',$email,$password); + if(!$myid) + $ok = 0; + } + else $ok = 0; if($ok) |