Commit 7dd56008 by James Cammarata

Allow empty include files again

Fixes #11582
parent 44aef347
...@@ -369,6 +369,8 @@ class StrategyBase: ...@@ -369,6 +369,8 @@ class StrategyBase:
try: try:
data = self._loader.load_from_file(included_file._filename) data = self._loader.load_from_file(included_file._filename)
if data is None:
return []
except AnsibleError, e: except AnsibleError, e:
for host in included_file._hosts: for host in included_file._hosts:
tr = TaskResult(host=host, task=included_file._task, return_data=dict(failed=True, reason=str(e))) tr = TaskResult(host=host, task=included_file._task, return_data=dict(failed=True, reason=str(e)))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment