mirror of
https://gitlab.com/davical-project/davical.git
synced 2026-08-31 18:46:02 +00:00
Use new function to get user record.
This commit is contained in:
parent
6fd430cbe3
commit
242d95fc08
@ -90,9 +90,7 @@ class BasicAuthSession {
|
||||
return call_user_func( $c->authenticate_hook['call'], $username, $password );
|
||||
}
|
||||
|
||||
$qry = new PgQuery( "SELECT * FROM usr WHERE lower(username) = lower(?) ", $username );
|
||||
if ( $qry->Exec('BasicAuth',__LINE__,__FILE__) && $qry->rows == 1 ) {
|
||||
$usr = $qry->Fetch();
|
||||
if ( $usr = getUserByName($username) ) {
|
||||
dbg_error_log( "BasicAuth", ":CheckPassword: Name:%s, Pass:%s, File:%s", $username, $password, $usr->password );
|
||||
if ( session_validate_password( $password, $usr->password ) ) {
|
||||
return $usr;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user