Source

iredadmin-ose / libs / mysql / connUtils.py

Diff from to

File libs/mysql/connUtils.py

 
 class Utils(core.MySQLWrap):
 
-    def isDomainExists(self, domain):
+    def is_domain_exists(self, domain):
         # Return True if account is invalid or exist.
         domain = str(domain)
-        if not iredutils.isDomain(domain):
+        if not iredutils.is_domain(domain):
             return True
 
         sql_vars = {'domain': domain, }
     def isAdminExists(self, mail):
         # Return True if account is invalid or exist.
         mail = str(mail)
-        if not iredutils.isEmail(mail):
+        if not iredutils.is_email(mail):
             return True
 
         try:
             return True
 
     # Check whether account exist or not.
-    def isEmailExists(self, mail):
+    def is_email_exists(self, mail):
         # Return True if account is invalid or exist.
         mail = web.safestr(mail)
 
-        if not iredutils.isEmail(mail):
+        if not iredutils.is_email(mail):
             return True
 
         sql_vars = {'email': mail, }
     def getManagedDomains(self, admin, domainNameOnly=False, listedOnly=False,):
         admin = web.safestr(admin)
 
-        if not iredutils.isEmail(admin):
+        if not iredutils.is_email(admin):
             return (False, 'INCORRECT_USERNAME')
 
         sql_left_join = ''
             if domainNameOnly is True:
                 domains = []
                 for i in result:
-                    if iredutils.isDomain(i.domain):
+                    if iredutils.is_domain(i.domain):
                         domains += [str(i.domain).lower()]
 
                 return (True, domains)