From d92e8edf6e7f7b9eff503f268d1c0d11c2ac44a8 Mon Sep 17 00:00:00 2001 From: Shirou WAKAYAMA Date: Thu, 12 Mar 2015 12:36:50 +0900 Subject: [PATCH] set 'nonstring' arg to passthru. --- lib/ansible/utils/template.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/ansible/utils/template.py b/lib/ansible/utils/template.py index 919436895a9..a58b9399715 100644 --- a/lib/ansible/utils/template.py +++ b/lib/ansible/utils/template.py @@ -184,8 +184,7 @@ class _jinja2_vars(object): var = self.vars[varname] # HostVars is special, return it as-is, as is the special variable # 'vars', which contains the vars structure - if type(var) == str: - var = to_unicode(var) + var = to_unicode(var, nonstring="passthru") if isinstance(var, dict) and varname == "vars" or isinstance(var, HostVars): return var else: