listify lookup plugin terms when they're specified as "{{ lookup(terms) }}"

Before this, they were not listified there but they were listified when
specified like this:

with_lookup: terms
This commit is contained in:
Toshio Kuratomi
2015-08-10 09:07:37 -07:00
parent e32d887609
commit d35b956900
23 changed files with 16 additions and 50 deletions

View File

@@ -251,6 +251,7 @@ class Templar:
instance = self._lookup_loader.get(name.lower(), loader=self._loader, templar=self)
if instance is not None:
loop_terms = listify_lookup_plugin_terms(terms=8args, templar=self, loader=self._loader, fail_on_undefined=True)
# safely catch run failures per #5059
try:
ran = instance.run(*args, variables=self._available_variables, **kwargs)