diff --git a/src/LdapSyncCommand.php b/src/LdapSyncCommand.php index 75500af..211b852 100644 --- a/src/LdapSyncCommand.php +++ b/src/LdapSyncCommand.php @@ -829,6 +829,11 @@ private function getLdapUsersAndGroups(array $config, array &$users, int &$users continue; } + if ($this->in_array_i($ldapGroupMemberName, $config["gitlab"]["options"]["userNamesToIgnore"])) { + $this->logger->info(sprintf("Group #%d / member #%d: User \"%s\" in ignore list.", $n, $o, $ldapGroupMemberName)); + continue; + } + if (!isset($users[$ldapGroupMemberName]) || !is_array($users[$ldapGroupMemberName])) { $this->logger->warning(sprintf("Group #%d / member #%d: User not found \"%s\".", $n, $o, $ldapGroupMemberName)); continue;