diff options
author | Andrew Dolgov <[email protected]> | 2010-07-28 14:32:09 +0400 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2010-07-28 14:32:09 +0400 |
commit | a7a9968684dca544e46e6da5338c9a452b1d8f24 (patch) | |
tree | 2d06504ede344d45516e35c8edc7ab0f9f89e41c /api | |
parent | 423e6e55d7c022e1efa1f171fd5c09caf8f01518 (diff) |
api: properly handle incorrect UID passed to login
Diffstat (limited to 'api')
-rw-r--r-- | api/index.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/api/index.php b/api/index.php index 64e9741a3..8d69e1a73 100644 --- a/api/index.php +++ b/api/index.php @@ -61,7 +61,7 @@ $uid = 0; } - if (get_pref($link, "ENABLE_API_ACCESS", $uid)) { + if ($uid && get_pref($link, "ENABLE_API_ACCESS", $uid)) { if (authenticate_user($link, $login, $password)) { print json_encode(array("session_id" => session_id())); } else { |