fixing URL parsing

This commit is contained in:
brent s 2018-05-08 10:04:05 -04:00
parent 4f775159c8
commit 07ab9840ca

View File

@ -319,20 +319,16 @@ class CertParse(object):

def validDomain(self, domain):
is_valid = False
try:
validators.domain(domain)
if not isinstance(validators.domain(domain),
validators.utils.ValidationFailure):
is_valid = True
except ValidationFailure:
pass
return(is_valid)

def validURL(self, url):
is_valid = False
try:
validators.url(url)
if not isinstance(validators.url(url),
validators.utils.ValidationFailure):
is_valid = True
except ValidationFailure:
pass
return(is_valid)

def validPath(self, path):