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:
Sumit Jaiswal 2019-07-17 02:52:19 +05:30 committed by Toshio Kuratomi
parent 396e48b36e
commit 5fb2a0ae2d
2 changed files with 8 additions and 4 deletions

View file

@ -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).

View file

@ -280,6 +280,7 @@ def main():
state = module.params['state']
tenant = module.params['tenant']
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: