From 69e5f2ae673069c926880ac880773ea4d2982e5b Mon Sep 17 00:00:00 2001 From: Peter Sprygada Date: Tue, 21 Mar 2017 06:41:59 -0700 Subject: [PATCH] fixes return data structure (#22830) The return was being re-written instead of updated so warnings were lost. This patch now updates the result instead of replacing it. (cherry picked from commit d6787632c94baf2e05edcc8377da31b6254c86a7) --- lib/ansible/modules/network/ios/ios_command.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/ansible/modules/network/ios/ios_command.py b/lib/ansible/modules/network/ios/ios_command.py index 0dfec3690dd..e96845fb37c 100644 --- a/lib/ansible/modules/network/ios/ios_command.py +++ b/lib/ansible/modules/network/ios/ios_command.py @@ -218,11 +218,11 @@ def main(): module.fail_json(msg=msg, failed_conditions=failed_conditions) - result = { + result.update({ 'changed': False, 'stdout': responses, 'stdout_lines': list(to_lines(responses)) - } + }) module.exit_json(**result)