[dev] ldap preferences patch

KaalH! kaalh@smol.org
Tue, 23 Jul 2002 15:44:32 +0200


Fix error when preferences not exists in ldap tree

Index: ldap.php
===================================================================
RCS file: /repository/horde/lib/Prefs/ldap.php,v
retrieving revision 1.41
diff -u -r1.41 ldap.php
--- ldap.php    18 Jul 2002 18:42:54 -0000  1.41
+++ ldap.php    23 Jul 2002 13:39:39 -0000
@@ -352,7 +358,7 @@
         /* ldap_get_entries() converts attribute indexes to lowercase. */
         $field = strtolower($this->scope . 'prefs');

-        if (isset($result)) {
+        if (isset($result[0][$field])) {
             /* Set the requested values in the $this->prefs hash based on
                the contents of the LDAP result.


-- 
KaalH!