Fixing error handling
This commit is contained in:
parent
6a5ab25264
commit
eb31af5a47
1 changed files with 2 additions and 1 deletions
|
@ -239,7 +239,8 @@ def load_config(module, candidate):
|
|||
def execute_config_command(commands, module):
|
||||
try:
|
||||
body = module.configure(commands)
|
||||
except ShellError, clie:
|
||||
except ShellError:
|
||||
clie = get_exception()
|
||||
module.fail_json(msg='Error sending CLI commands',
|
||||
error=str(clie), commands=commands)
|
||||
return body
|
||||
|
|
Loading…
Reference in a new issue