From 09ab3f95d043090d86f166c5dfb1dcae6a873faa Mon Sep 17 00:00:00 2001 From: Joshua Roesslein Date: Tue, 17 Nov 2009 14:45:57 +0800 Subject: Be sure to cast value to a string for unescaped tags. --- pystache/template.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pystache/template.py b/pystache/template.py index 10b72aa..7776a7b 100644 --- a/pystache/template.py +++ b/pystache/template.py @@ -104,7 +104,7 @@ class Template(object): @modifier('{') def render_unescaped(self, tag_name=None, context=None): """Render a tag without escaping it.""" - return context.get(tag_name, '') + return str(context.get(tag_name, '')) @modifier('>') def render_partial(self, tag_name=None, context=None): -- cgit v1.2.1