1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Merge pull request #223 from jkleint/devel

runner._chain_file_module() calls .get() on error string
This commit is contained in:
Michael DeHaan 2012-04-24 13:52:58 -07:00
commit 2999b6b2c4

View file

@ -456,8 +456,11 @@ class Runner(object):
(result2, err2, executed2) = self._execute_module(conn, tmp, module, args) (result2, err2, executed2) = self._execute_module(conn, tmp, module, args)
results2 = self._return_from_module(conn, conn.host, result2, err2, executed) results2 = self._return_from_module(conn, conn.host, result2, err2, executed)
(host, ok, data2, err2) = results2 (host, ok, data2, err2) = results2
if ok:
new_changed = data2.get('changed', False) new_changed = data2.get('changed', False)
data.update(data2) data.update(data2)
else:
new_changed = False
if old_changed or new_changed: if old_changed or new_changed:
data['changed'] = True data['changed'] = True
return (host, ok, data, "%s%s"%(err,err2)) return (host, ok, data, "%s%s"%(err,err2))