mirror of
https://github.com/NaN-tic/trytond-electronic_mail-old.git
synced 2023-12-14 02:22:55 +01:00
Get email: email file is None when not have _get_mail
This commit is contained in:
parent
f8d538e2d1
commit
94005e35f5
|
@ -509,7 +509,7 @@ class ElectronicMail(ModelSQL, ModelView):
|
|||
for fname in ['body_plain', 'body_html', 'num_attach', 'email_file']:
|
||||
result[fname] = {}
|
||||
for mail in mails:
|
||||
email_file = cls._get_email(mail) or False
|
||||
email_file = cls._get_email(mail) or None
|
||||
result['email_file'][mail.id] = email_file
|
||||
email = msg_from_string(email_file)
|
||||
body = cls.get_body(mail, email)
|
||||
|
|
Loading…
Reference in a new issue