Merge branch 'master' of github.com:webnotes/wnframework into handlerupdate
This commit is contained in:
commit
facecf2a1e
1 changed files with 4 additions and 4 deletions
|
|
@ -61,8 +61,8 @@ class EMail:
|
|||
Attach message in the text portion of multipart/alternative
|
||||
"""
|
||||
from email.mime.text import MIMEText
|
||||
if type(message) is not unicode:
|
||||
message = unicode(message, 'utf-8')
|
||||
#if type(message) is not unicode:
|
||||
# message = unicode(message, 'utf-8')
|
||||
part = MIMEText(message.encode('utf-8'), 'plain', 'UTF-8')
|
||||
self.msg_multipart.attach(part)
|
||||
|
||||
|
|
@ -71,8 +71,8 @@ class EMail:
|
|||
Attach message in the html portion of multipart/alternative
|
||||
"""
|
||||
from email.mime.text import MIMEText
|
||||
if type(message) is not unicode:
|
||||
message = unicode(message, 'utf-8')
|
||||
#if type(message) is not unicode:
|
||||
# message = unicode(message, 'utf-8')
|
||||
part = MIMEText(message.encode('utf-8'), 'html')
|
||||
self.msg_multipart.attach(part)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue