Commit 935d2a02 by Kálmán Viktor

fixing mx validator

parent 11eecb2c
...@@ -78,7 +78,7 @@ def val_mx(value): ...@@ -78,7 +78,7 @@ def val_mx(value):
Expected form is <priority>:<hostname>. Expected form is <priority>:<hostname>.
""" """
mx = self.address.split(':', 1) mx = value.split(':', 1)
if not (len(mx) == 2 and mx[0].isdigit() and if not (len(mx) == 2 and mx[0].isdigit() and
domain_re.match(mx[1])): domain_re.match(mx[1])):
raise ValidationError(_("Bad MX address format. " raise ValidationError(_("Bad MX address format. "
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment