mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-04-01 08:13:08 +00:00
Do not escape backslashes when using the template lookup plugin
This brings the lookup plugin inline with what the template module does. Fixes #26397
This commit is contained in:
@@ -68,7 +68,8 @@ class LookupModule(LookupBase):
|
||||
self._templar.set_available_variables(temp_vars)
|
||||
|
||||
# do the templating
|
||||
res = self._templar.template(template_data, preserve_trailing_newlines=True, convert_data=convert_data_p)
|
||||
res = self._templar.template(template_data, preserve_trailing_newlines=True,
|
||||
convert_data=convert_data_p, escape_backslashes=False)
|
||||
ret.append(res)
|
||||
else:
|
||||
raise AnsibleError("the template file %s could not be found for the lookup" % term)
|
||||
|
||||
Reference in New Issue
Block a user