Backport PR to resolve NoneType error in issue 57711 (#58706)
* fix 57711 (#58618)
Signed-off-by: Sumit Jaiswal <sjaiswal@redhat.com>
(cherry picked from commit 8b844b67b5
)
* changelog file
This commit is contained in:
parent
396e48b36e
commit
5fb2a0ae2d
2 changed files with 8 additions and 4 deletions
|
@ -0,0 +1,3 @@
|
|||
bugfixes:
|
||||
- To resolve NoneType error as it was missing NoneType check for l3protocol param in aci_l3out.
|
||||
(https://github.com/ansible/ansible/pull/58618).
|
|
@ -280,10 +280,11 @@ def main():
|
|||
state = module.params['state']
|
||||
tenant = module.params['tenant']
|
||||
|
||||
if 'eigrp' in l3protocol and asn is None:
|
||||
module.fail_json(msg="Parameter 'asn' is required when l3protocol is 'eigrp'")
|
||||
if 'eigrp' not in l3protocol and asn is not None:
|
||||
module.warn("Parameter 'asn' is only applicable when l3protocol is 'eigrp'. The ASN will be ignored")
|
||||
if l3protocol:
|
||||
if 'eigrp' in l3protocol and asn is None:
|
||||
module.fail_json(msg="Parameter 'asn' is required when l3protocol is 'eigrp'")
|
||||
if 'eigrp' not in l3protocol and asn is not None:
|
||||
module.warn("Parameter 'asn' is only applicable when l3protocol is 'eigrp'. The ASN will be ignored")
|
||||
|
||||
enforce_ctrl = ''
|
||||
if enforceRtctrl is not None:
|
||||
|
|
Loading…
Reference in a new issue