Users using the Tequila login are invited to migrate to gitlab.epfl.ch. This instance will close for Tequila users by May 2020.

Commit 22d6f153 authored by Timothée Floure's avatar Timothée Floure

Do not crash if LDAP group does not exist

parent 42c15587
Pipeline #1186 failed
......@@ -156,7 +156,7 @@ def main
filter = Net::LDAP::Filter.eq('cn', list_name)
matched_ldap_groups = conn.search(base: basetree, filter: filter)
if matched_ldap_groups.empty?
if matched_ldap_groups.nil? || matched_ldap_groups.empty?
# Could not find matching LDAP group
puts 'NOT FOUND'
else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment