From 6d19caab414b0015d780a9808ac5e037397b8e07 Mon Sep 17 00:00:00 2001 From: danstowell Date: Thu, 6 Jul 2006 13:13:42 +0000 Subject: [PATCH] Change to make LDAP enroller simply ignore accounts with blank idnumber - see moodle.org discussion with Inaki --- enrol/ldap/enrol.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/enrol/ldap/enrol.php b/enrol/ldap/enrol.php index 0664da8f57..93bc7115d9 100755 --- a/enrol/ldap/enrol.php +++ b/enrol/ldap/enrol.php @@ -485,6 +485,10 @@ function find_ext_enrolments ($ldap_connection, $memberuid, $type){ global $CFG; + if(empty($memberuid)) { // No "idnumber" stored for this user, so no LDAP enrolments + return array(); + } + //default return value $courses = array(); $this->enrol_ldap_bind($ldap_connection); -- 2.39.5