Merge "Stop using deprecated implicit_prefix option"
This commit is contained in:
commit
1cfe32d7ec
|
@ -106,7 +106,7 @@ class CIDRConstraint(constraints.BaseCustomConstraint):
|
|||
|
||||
def validate(self, value, context, template=None):
|
||||
try:
|
||||
netaddr.IPNetwork(value, implicit_prefix=True)
|
||||
netaddr.IPNetwork(netaddr.cidr_abbrev_to_verbose(value))
|
||||
msg = validators.validate_subnet(value)
|
||||
if msg is not None:
|
||||
self._error_message = msg
|
||||
|
|
Loading…
Reference in New Issue