mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
Fixes #6845 evaluate changed_when only if task is not skipped
This commit is contained in:
parent
085d9aee72
commit
318e752b6f
1 changed files with 1 additions and 1 deletions
|
@ -873,7 +873,7 @@ class Runner(object):
|
|||
# only run the final checks if the async_status has finished,
|
||||
# or if we're not running an async_status check at all
|
||||
if (module_name == 'async_status' and "finished" in data) or module_name != 'async_status':
|
||||
if changed_when is not None:
|
||||
if changed_when is not None and 'skipped' not in data:
|
||||
data['changed'] = utils.check_conditional(changed_when, self.basedir, inject, fail_on_undefined=self.error_on_undefined_vars)
|
||||
if failed_when is not None:
|
||||
data['failed_when_result'] = data['failed'] = utils.check_conditional(failed_when, self.basedir, inject, fail_on_undefined=self.error_on_undefined_vars)
|
||||
|
|
Loading…
Reference in a new issue