mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-25 14:20:22 -07:00
check_mode in nxos_static_route module (#44252)
Signed-off-by: Trishna Guha <trishnaguha17@gmail.com>
This commit is contained in:
parent
aef5099695
commit
7e39c5bf07
1 changed files with 1 additions and 3 deletions
|
@ -280,13 +280,11 @@ def main():
|
||||||
candidate = CustomNetworkConfig(indent=3)
|
candidate = CustomNetworkConfig(indent=3)
|
||||||
reconcile_candidate(module, candidate, prefix, w)
|
reconcile_candidate(module, candidate, prefix, w)
|
||||||
|
|
||||||
if candidate:
|
if not module.check_mode and candidate:
|
||||||
candidate = candidate.items_text()
|
candidate = candidate.items_text()
|
||||||
load_config(module, candidate)
|
load_config(module, candidate)
|
||||||
result['commands'].extend(candidate)
|
result['commands'].extend(candidate)
|
||||||
result['changed'] = True
|
result['changed'] = True
|
||||||
else:
|
|
||||||
result['commands'] = []
|
|
||||||
|
|
||||||
module.exit_json(**result)
|
module.exit_json(**result)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue