mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-07 13:52:54 +00:00
multiple fixes nxos (#32903)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
This commit is contained in:
@@ -169,7 +169,7 @@ class Cli:
|
||||
except ValueError:
|
||||
out = to_text(out).strip()
|
||||
|
||||
if item['output'] == 'json' and out != 'ok' and isinstance(out, string_types):
|
||||
if item['output'] == 'json' and out != '' and isinstance(out, string_types):
|
||||
self._module.fail_json(msg='failed to retrieve output of %s in json format' % item['command'])
|
||||
|
||||
responses.append(out)
|
||||
|
||||
@@ -488,6 +488,9 @@ def get_interface_config_commands(interface, intf, existing):
|
||||
if mtu != 'None':
|
||||
commands.append('mtu {0}'.format(mtu))
|
||||
|
||||
if 'mtu None' in commands:
|
||||
commands.pop()
|
||||
|
||||
admin_state = interface.get('admin_state')
|
||||
if admin_state:
|
||||
command = get_admin_state(interface, intf, admin_state)
|
||||
|
||||
Reference in New Issue
Block a user