1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

template also when only comments present

This commit is contained in:
Brian Coca 2016-02-16 09:42:33 -05:00
parent 6ddea3e915
commit 6102a4b9b4

View file

@ -370,7 +370,10 @@ class Templar:
'''
returns True if the data contains a variable pattern
'''
return self.environment.block_start_string in data or self.environment.variable_start_string in data
for marker in [self.environment.block_start_string, self.environment.variable_start_string, self.environment.comment_start_string]:
if marker in data:
return True
return False
def _convert_bare_variable(self, variable, bare_deprecated):
'''