fixed email locale detection

This commit is contained in:
maccesch 2011-09-01 17:23:31 +02:00
parent c8be4b03e2
commit 652f847c3b

View File

@ -54,9 +54,7 @@ def send_templated_mail(template_name, email_context, recipients, sender=None, b
import os
context = Context(email_context)
locale = getattr(context['queue'], 'locale', '')
if not locale:
locale = 'en'
locale = context['queue'].get('locale', 'en')
t = None
try: