From fa7387420a9a97b83c34b282117398989710df04 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Elliott=20B=C3=A9cue?= Date: Thu, 10 Sep 2015 14:52:57 +0200 Subject: [PATCH] =?UTF-8?q?On=20passe=20le=20TLD=20pour=20la=20regexp=20ma?= =?UTF-8?q?il=20=C3=A0=2020?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * .cancerresearch fait déjà 14 --- attributs.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/attributs.py b/attributs.py index 6070c7b..7404e82 100644 --- a/attributs.py +++ b/attributs.py @@ -766,7 +766,7 @@ class mail(rightProtectedAttr): raise ValueError("Le mail %s est déjà pris." % (str(self))) def parse_value(self, mail): - if not re.match(u'^[-_.0-9A-Za-z]+@([A-Za-z0-9]{1}[A-Za-z0-9-_]+[.])+[a-z]{2,6}$', mail): + if not re.match(u'^[-_.0-9A-Za-z]+@([A-Za-z0-9]{1}[A-Za-z0-9-_]+[.])+[a-z]{2,20}$', mail): raise ValueError("%s invalide %r" % (self.legend, mail)) self.value = mail