Browse Source

[FIX] use v7 style write

pull/1/head
Ivan Yelizariev 10 years ago
parent
commit
59dbab6bf0
  1. 2
      mail_fix_553.py

2
mail_fix_553.py

@ -20,5 +20,5 @@ class mail_mail(osv.osv):
for mail in self.browse(cr, SUPERUSER_ID, ids, context=context): for mail in self.browse(cr, SUPERUSER_ID, ids, context=context):
email_from = mail.email_from email_from = mail.email_from
if not email_from or re.search(correct_email_from, email_from) is None: if not email_from or re.search(correct_email_from, email_from) is None:
mail.email_from = default_email_from
mail.write({'email_from': default_email_from})
return super(mail_mail, self).send(cr, uid, ids, context=context, **kwargs) return super(mail_mail, self).send(cr, uid, ids, context=context, **kwargs)
Loading…
Cancel
Save