Source

iredadmin-ose / libs / iredutils.py

Diff from to

libs/iredutils.py

 INVALID_DOMAIN_CHARS = '~!#$%^&*()+\\/\ '
 
 
-def isEmail(s):
+def is_email(s):
     s = str(s)
     if len(set(s) & set(INVALID_EMAIL_CHARS)) > 0 \
        or '.' not in s \
         return False
 
 
-def isDomain(s):
+def is_domain(s):
     s = str(s)
     if len(set(s) & set(INVALID_DOMAIN_CHARS)) > 0 or '.' not in s:
         return False
     """Generate path of mailbox."""
 
     mail = web.safestr(mail)
-    if not isEmail(mail):
+    if not is_email(mail):
         return (False, 'INVALID_EMAIL_ADDRESS')
 
     # Get user/domain part from mail address.