mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Do not print empty diffs with _display.display()
This commit is contained in:
parent
28169492f9
commit
c902f926ca
1 changed files with 6 additions and 2 deletions
|
@ -138,9 +138,13 @@ class CallbackModule(CallbackBase):
|
|||
if result._task.loop and 'results' in result._result:
|
||||
for res in result._result['results']:
|
||||
if 'diff' in res and res['diff']:
|
||||
self._display.display(self._get_diff(res['diff']))
|
||||
diff = self._get_diff(res['diff'])
|
||||
if diff:
|
||||
self._display.display(diff)
|
||||
elif 'diff' in result._result and result._result['diff']:
|
||||
self._display.display(self._get_diff(result._result['diff']))
|
||||
diff = self._get_diff(result._result['diff'])
|
||||
if diff:
|
||||
self._display.display(diff)
|
||||
|
||||
def v2_playbook_item_on_ok(self, result):
|
||||
|
||||
|
|
Loading…
Reference in a new issue