fixing URL parsing
This commit is contained in:
parent
4f775159c8
commit
07ab9840ca
@ -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):
|
||||
|
Loading…
Reference in New Issue
Block a user