diff --git a/gestion/ldap_crans.py b/gestion/ldap_crans.py index 83289609..189d6125 100644 --- a/gestion/ldap_crans.py +++ b/gestion/ldap_crans.py @@ -2839,8 +2839,7 @@ Contactez nounou si la MAC est bien celle d'une carte.""", 3) elif not isinstance(proprio, Adherent) or proprio.adherentPayant(): proprio_subnet = 'adherents' try: - chbre = proprio.chbre() - if chbre and chbre[0] == 'G': + if self.nom().endswith("-g.crans.org"): proprio_subnet = 'adh-g' net = config.NETs[proprio_subnet] pool_ip = lister_ip_dispo(proprio_subnet)