diff --git a/lib/ansible/module_utils/nxos.py b/lib/ansible/module_utils/nxos.py index c2d49c9002..3c8837e096 100644 --- a/lib/ansible/module_utils/nxos.py +++ b/lib/ansible/module_utils/nxos.py @@ -203,10 +203,8 @@ class NetworkModule(AnsibleModule): if self.params.get('include_defaults'): cmd += ' all' - if self.params['transport'] == 'cli': - return self.execute(cmd)[0] - else: - return self.execute(cmd) + response = self.execute(cmd) + return response[0] def get_module(**kwargs): """Return instance of NetworkModule