From f02e8bfd61bf6ae75d5206256f1fafe3fa924148 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thibault=20Delavall=C3=A9e?= Date: Thu, 21 Mar 2013 12:28:23 +0100 Subject: [PATCH] [FIX] Broltch bzr revid: tde@openerp.com-20130321112823-nmqzcjzigiwt09q7 --- addons/mail/mail_thread.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/mail/mail_thread.py b/addons/mail/mail_thread.py index 6b0cb5f7bc5..04492cdcbc4 100644 --- a/addons/mail/mail_thread.py +++ b/addons/mail/mail_thread.py @@ -940,9 +940,9 @@ class mail_thread(osv.AbstractModel): del context['thread_model'] return self.pool.get(model).message_post(cr, uid, thread_id, body=body, subject=subject, type=type, subtype=subtype, parent_id=parent_id, attachments=attachments, context=context, content_subtype=content_subtype, **kwargs) - # 0: Parse email-from, try to find a better author_id based on document's followers + # 0: Parse email-from, try to find a better author_id based on document's followers for incoming emails email_from = kwargs.get('email_from') - if email_from and thread_id: + if email_from and thread_id and type == 'email': email_list = tools.email_split(email_from) doc = self.browse(cr, uid, thread_id, context=context) if email_list and doc: