Skip to content
Browse files

turn on autoescaping explicitly if not a text notice (pinax bug #394)

  • Loading branch information...
1 parent e04fdc9 commit 62cc7468c461f6a0feb5e285fa1b6088591281e2 @jtauber jtauber committed Aug 15, 2009
Showing with 2 additions and 0 deletions.
  1. +2 −0 notification/models.py
View
2 notification/models.py
@@ -223,6 +223,8 @@ def get_formatted_messages(formats, label, context):
# conditionally turn off autoescaping for .txt extensions in format
if format.endswith(".txt"):
context.autoescape = False
+ else:
+ context.autoescape = True
format_templates[format] = render_to_string((
'notification/%s/%s' % (label, format),
'notification/%s' % format), context_instance=context)

0 comments on commit 62cc746

Please sign in to comment.
Something went wrong with that request. Please try again.