diff options
Diffstat (limited to 'django')
| -rw-r--r-- | django/core/mail/message.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/django/core/mail/message.py b/django/core/mail/message.py index 9a0f0eba45..2f89ffbfc4 100644 --- a/django/core/mail/message.py +++ b/django/core/mail/message.py @@ -170,7 +170,7 @@ class SafeMIMEText(MIMEMixin, MIMEText): MIMEText.__setitem__(self, name, val) def set_payload(self, payload, charset=None): - if charset == 'utf-8': + if charset == 'utf-8' and not isinstance(charset, Charset.Charset): has_long_lines = any( len(l.encode()) > RFC5322_EMAIL_LINE_LENGTH_LIMIT for l in payload.splitlines() |
