validation should not raises ValueError
This commit is contained in:
parent
e32820c913
commit
7e281235bc
|
@ -46,7 +46,7 @@ class BroadcastOption(Option):
|
|||
|
||||
def _cons_broadcast(self, current_opt, opts, vals, warnings_only):
|
||||
if len(vals) != 3:
|
||||
raise ConfigError(_('invalid len for vals'))
|
||||
return ConfigError(_('invalid len for vals'))
|
||||
if None in vals:
|
||||
return
|
||||
broadcast, network, netmask = vals
|
||||
|
|
|
@ -84,7 +84,7 @@ class IPOption(Option):
|
|||
|
||||
def _cons_in_network(self, current_opt, opts, vals, warnings_only):
|
||||
if len(vals) != 3:
|
||||
raise ConfigError(_('invalid len for vals'))
|
||||
return ConfigError(_('invalid len for vals'))
|
||||
if None in vals:
|
||||
return
|
||||
ip, network, netmask = vals
|
||||
|
|
Loading…
Reference in New Issue