From c56c5cf1e2b5c3de0a12d0ef0031efdee19fad11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thibault=20Delavall=C3=A9e?= Date: Thu, 28 May 2015 13:51:01 +0200 Subject: [PATCH] [CLEAN] mail: removed duplicated code --- addons/mail/wizard/mail_compose_message.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/addons/mail/wizard/mail_compose_message.py b/addons/mail/wizard/mail_compose_message.py index 2a8957fa35f..2c7c5b7894d 100644 --- a/addons/mail/wizard/mail_compose_message.py +++ b/addons/mail/wizard/mail_compose_message.py @@ -94,9 +94,6 @@ class MailComposer(models.TransientModel): result['model'] = 'res.partner' result['res_id'] = self.env.user.partner_id.id - if fields is not None: - [result.pop(field, None) for field in result.keys() if field not in fields] - # Override to pre-fill the data when having a template in single-email mode # and not going through the view: the on_change is not called in that case. if result.get('composition_mode') != 'mass_mail' and self._context.get('default_template_id') and result.get('model') and result.get('res_id'):