removed deprecated 'bare' templating environment (#17640)
https://docs.ansible.com/ansible/porting_guide_2.0.html#deprecated
This commit is contained in:
parent
943f4ebccf
commit
1b0b6b4c10
1 changed files with 2 additions and 2 deletions
|
@ -270,12 +270,12 @@ class Task(Base, Conditional, Taggable, Become):
|
|||
env = []
|
||||
for env_item in value:
|
||||
if isinstance(env_item, (string_types, AnsibleUnicode)) and env_item in templar._available_variables.keys():
|
||||
env[env_item] = templar.template(env_item, convert_bare=True)
|
||||
env[env_item] = templar.template(env_item, convert_bare=False)
|
||||
elif isinstance(value, dict):
|
||||
env = dict()
|
||||
for env_item in value:
|
||||
if isinstance(env_item, (string_types, AnsibleUnicode)) and env_item in templar._available_variables.keys():
|
||||
env[env_item] = templar.template(value[env_item], convert_bare=True)
|
||||
env[env_item] = templar.template(value[env_item], convert_bare=False)
|
||||
|
||||
# at this point it should be a simple string
|
||||
return templar.template(value, convert_bare=True)
|
||||
|
|
Loading…
Reference in a new issue