From 6a089a7214ec2f1b2ca36f73c5c5faba82e512d9 Mon Sep 17 00:00:00 2001 From: Chuck Hagenbuch Date: Wed, 2 Jun 2010 17:08:16 -0400 Subject: [PATCH] Fix parse error and bad variable that prevented Sql auth from working --- framework/Auth/lib/Horde/Auth/Sql.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/framework/Auth/lib/Horde/Auth/Sql.php b/framework/Auth/lib/Horde/Auth/Sql.php index a228cc122..12f551cb4 100644 --- a/framework/Auth/lib/Horde/Auth/Sql.php +++ b/framework/Auth/lib/Horde/Auth/Sql.php @@ -113,12 +113,12 @@ class Horde_Auth_Sql extends Horde_Auth_Base $values = array($userId); try { - $result = $this->_db->selectOne($query, $values); + $row = $this->_db->selectOne($query, $values); } catch (Horde_Db_Exception $e) { throw new Horde_Auth_Exception('', Horde_Auth::REASON_FAILED); } - if (!$result || + if (!$row || !$this->_comparePasswords($row[$this->_params['password_field']], $credentials['password'])) { throw new Horde_Auth_Exception('', Horde_Auth::REASON_BADLOGIN); } @@ -218,7 +218,7 @@ class Horde_Auth_Sql extends Horde_Auth_Base } } - $query = .= sprintf('WHERE %s = ?', $this->_params['username_field']); + $query .= sprintf('WHERE %s = ?', $this->_params['username_field']); $values[] = $oldID; try { -- 2.11.0