LafColITS / moodle-local_ldap

Various synchronization scripts between Moodle and LDAP directories (see https://tracker.moodle.org/browse/MDL-25011 )
9 stars 7 forks source link

Nested group synchronization fails if the included group has no members #41

Closed raphael247 closed 6 months ago

raphael247 commented 6 months ago

Synchronization of a nested group fails if the containing group has no members.

line: 395 in: local/ldap/locallib.php Funktion: ldap_get_group_members_ad

...
$tmp = $this->ldap_get_group_members_ad($groupcn);
if (!$tmp) {
     return false;
}
...

the $tmp variable will be an array with size 0.

I think, there is the same problem in function ldap_get_group_members_rfc

mackensen commented 6 months ago

@raphael247 which version of the plugin are you using? The most recent release (v4.1.0) contains a fix for this issue.

raphael247 commented 6 months ago

Ups, I'm using: $plugin->release = 'v3.11.1';

I just looked at the code - it is the same fix, I would have proposed.