We were already using QP for HTML emails, but due to an oversight it
wasn't done for the pure plaintext ones. Fix that as it's a lot easier
to debug that way, and it's what most MUAs do so it should lead to lower
spam scores.
mpart.attach(MIMEText(htmlbody, 'html', _charset=_utf8_charset))
else:
# Just a plaintext body, so append it directly
mpart.attach(MIMEText(htmlbody, 'html', _charset=_utf8_charset))
else:
# Just a plaintext body, so append it directly
- mpart = MIMEText(msgtxt, _charset='utf-8')
+ mpart = MIMEText(msgtxt, _charset=_utf8_charset)
if attachments:
msg = MIMEMultipart()
if attachments:
msg = MIMEMultipart()