Merge pull request #100 from keitaroinc/mailer-names-fix
Mailer names fix
This commit is contained in:
commit
f9ee4667df
|
@ -0,0 +1,11 @@
|
|||
--- ckan/ckan/lib/mailer.py
|
||||
+++ ckan/ckan/lib/mailer.py
|
||||
@@ -55,7 +55,7 @@ def _mail_recipient(recipient_name, recipient_email,
|
||||
msg.add_header(k, v)
|
||||
subject = Header(subject.encode('utf-8'), 'utf-8')
|
||||
msg['Subject'] = subject
|
||||
- msg['From'] = _("%s <%s>") % (sender_name, mail_from)
|
||||
+ msg['From'] = utils.formataddr((sender_name, mail_from))
|
||||
msg['To'] = u"%s <%s>" % (recipient_name, recipient_email)
|
||||
msg['Date'] = utils.formatdate(time())
|
||||
msg['X-Mailer'] = "CKAN %s" % ckan.__version__
|
|
@ -0,0 +1,11 @@
|
|||
--- ckan/ckan/lib/mailer.py
|
||||
+++ ckan/ckan/lib/mailer.py
|
||||
@@ -56,7 +56,7 @@ def _mail_recipient(recipient_name, recipient_email,
|
||||
subject = Header(subject.encode('utf-8'), 'utf-8')
|
||||
msg['Subject'] = subject
|
||||
msg['From'] = utils.formataddr((sender_name, mail_from))
|
||||
- msg['To'] = u"%s <%s>" % (recipient_name, recipient_email)
|
||||
+ msg['To'] = utils.formataddr((recipient_name, recipient_email))
|
||||
msg['Date'] = utils.formatdate(time())
|
||||
msg['X-Mailer'] = "CKAN %s" % ckan.__version__
|
||||
# Check if extension is setting reply-to via headers or use config option
|
Loading…
Reference in New Issue