Commit ce244b8079ff733cbdf690ce5aa0be59159321d4
1 parent
4f13e9a9
Use DBUtil for this query, it was not database-portable previously.
git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@3297 c91229c3-7414-0410-bfa2-8a42b809f60b
Showing
1 changed file
with
3 additions
and
1 deletions
lib/authentication/Authenticator.inc
| ... | ... | @@ -40,7 +40,9 @@ class Authenticator { |
| 40 | 40 | $aUserDetails = array(); |
| 41 | 41 | |
| 42 | 42 | // retrieve the userID |
| 43 | - $iUserID = lookupID($default->users_table, "BINARY username", "$sUserName"); | |
| 43 | + $sSQL = "SELECT id FROM $default->users_table WHERE username = ?"; | |
| 44 | + $aParams = array($sUserName); | |
| 45 | + $iUserID = DBUtil::getOneResultKey(array($sSQL, $aParams), 'id'); | |
| 44 | 46 | if ($iUserID) { |
| 45 | 47 | $oUser = & User::get($iUserID); |
| 46 | 48 | ... | ... |