-
- Downloads
Revert "[FIX] mail: remove attachment as main at unlink"
This reverts commit abc45b19 Since by default the ondelete attribute of a many2one is `set null`, this was completely unnecessary to begin with. Bug caused by this commit: Unlink a record that has some attachments. The unlink first removes the record, then its related attachments. It calls remove_as_main_attachment, which reads the attachment res_model and res_id. This triggers a check that the related record can be read. However the related record has already been removed, an exception is raised. It is thus impossible to unlink a record. Closes #32563 closes odoo/odoo#32572 Signed-off-by:Raphael Collet (rco) <rco@openerp.com>
Loading
Please register or sign in to comment