Permalink
Browse files

Fixed subject rendering. Also, it now throws an exception on error wh…

…en sending, so that you know that something is wrong.
  • Loading branch information...
mitar committed Sep 22, 2011
1 parent 1fa28b2 commit aa402a3e41890982f082e66aa2bd5e394492f137
Showing with 2 additions and 2 deletions.
  1. +2 −2 cmsplugin_contact/cms_plugins.py
@@ -99,7 +99,7 @@ def send(self, form, site_email):
email_message = EmailMessage(
render_to_string(self.subject_template, {
'subject': subject,
- }),
+ }).splitlines()[0],
render_to_string(self.email_template, {
'data': form.cleaned_data,
}),
@@ -108,7 +108,7 @@ def send(self, form, site_email):
headers = {
'Reply-To': form.cleaned_data['email']
},)
- email_message.send(fail_silently=True)
+ email_message.send(fail_silently=False)
def render(self, context, instance, placeholder):
request = context['request']

0 comments on commit aa402a3

Please sign in to comment.