From 298a81bc63d7de7974e0a61cb6c78c029b380b60 Mon Sep 17 00:00:00 2001 From: till Date: Tue, 1 Apr 2008 08:11:13 +0000 Subject: * debugging bind (simplyfied if/else) git-svn-id: https://svn.roundcube.net/trunk@1228 208e9e7b-5314-0410-a742-e7e81cd9613c --- roundcubemail/program/include/rcube_ldap.inc | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'roundcubemail/program/include') diff --git a/roundcubemail/program/include/rcube_ldap.inc b/roundcubemail/program/include/rcube_ldap.inc index 29e7faa6b..5403084b4 100644 --- a/roundcubemail/program/include/rcube_ldap.inc +++ b/roundcubemail/program/include/rcube_ldap.inc @@ -119,20 +119,20 @@ class rcube_ldap */ function bind($dn, $pass) { - if (!$this->conn) + if (!$this->conn) { return false; + } - if (@ldap_bind($this->conn, $dn, $pass)) + if (@ldap_bind($this->conn, $dn, $pass)) { return true; - else - { - raise_error(array( + } + + raise_error(array( 'code' => ldap_errno($this->conn), 'type' => 'ldap', 'message' => "Bind failed for dn=$dn: ".ldap_error($this->conn)), - true); - } - + true); + return false; } -- cgit v1.2.3