From f8e0ced9547d2d68a1045821f489dd4fa41728cb Mon Sep 17 00:00:00 2001 From: Jordan Delorme Date: Wed, 5 Mar 2014 22:16:49 +0100 Subject: [PATCH] [ldap_crans] Augmentation taille TLD MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Les TLD étaient limités à 3 caractères. Ils passent désormais à 5. --- gestion/ldap_crans.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gestion/ldap_crans.py b/gestion/ldap_crans.py index 3d521fc5..6d74a500 100755 --- a/gestion/ldap_crans.py +++ b/gestion/ldap_crans.py @@ -291,7 +291,7 @@ def validate_mail(mail, crans_allowed=False): # 2 à 4 caractères après le . final # @ pas en premier ni juste avant le dernier . if mail.count('@') != 1 \ - or not ( l-b >= 2 and l-b <= 4) \ + or not ( l-b >= 2 and l-b <= 6) \ or a < 1 or b-a < 2: raise ValueError(u"Adresse mail incorrecte.")