diff --git a/addons/crm/models/crm_lead.py b/addons/crm/models/crm_lead.py index b3adb24281f..d7d352b4efb 100644 --- a/addons/crm/models/crm_lead.py +++ b/addons/crm/models/crm_lead.py @@ -1306,6 +1306,11 @@ class Lead(models.Model): through message_process. This override updates the document according to the email. """ + + # remove external users + if self.env.user.has_group('base.group_portal'): + self = self.with_context(default_user_id=False) + # remove default author when going through the mail gateway. Indeed we # do not want to explicitly set user_id to False; however we do not # want the gateway user to be responsible if no other responsible is