mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-06-12 19:29:11 -07:00
Make sure the templar is using the right vars when evaluating conditionals
This commit is contained in:
parent
4cac10e016
commit
ff998b6022
1 changed files with 3 additions and 0 deletions
|
@ -73,6 +73,9 @@ class Conditional:
|
||||||
if conditional in all_vars and '-' not in unicode(all_vars[conditional]):
|
if conditional in all_vars and '-' not in unicode(all_vars[conditional]):
|
||||||
conditional = all_vars[conditional]
|
conditional = all_vars[conditional]
|
||||||
|
|
||||||
|
# make sure the templar is using the variables specifed to this method
|
||||||
|
templar.set_available_variables(variables=all_vars)
|
||||||
|
|
||||||
conditional = templar.template(conditional)
|
conditional = templar.template(conditional)
|
||||||
if not isinstance(conditional, basestring) or conditional == "":
|
if not isinstance(conditional, basestring) or conditional == "":
|
||||||
return conditional
|
return conditional
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue