0
0
mirror of https://github.com/postfixadmin/postfixadmin.git synced 2024-09-19 19:22:14 +02:00

move to use db_assoc() rather than db_array() (code assumes assoc. array)

This commit is contained in:
David Goodwin 2018-02-10 21:08:35 +00:00
parent c147eb053b
commit 152975d05c
2 changed files with 3 additions and 3 deletions

View File

@ -808,7 +808,7 @@ abstract class PFAHandler {
$result = db_query($query);
if ($result['rows'] == 1) {
$row = db_array($result['result']);
$row = db_assoc($result['result']);
$crypt_password = pacrypt($password, $row['password']);
if ($row['password'] == $crypt_password) {
@ -853,7 +853,7 @@ abstract class PFAHandler {
$result = db_query($query);
if ($result['rows'] == 1) {
$row = db_array($result['result']);
$row = db_assoc($result['result']);
$crypt_token = pacrypt($token, $row['token']);
if ($row['token'] == $crypt_token) {

View File

@ -149,7 +149,7 @@ class VacationHandler extends PFAHandler {
return false;
}
$row = db_array($result['result']);
$row = db_assoc($result['result']);
$boolean = ($row['active'] == db_get_boolean(true));
# TODO: only return true and store the db result array in $this->whatever for consistency with the other classes
return array(