odoo/odoo#194569
Created by SM Engagement, Julien Banken (jbn)
Merged
at 954d710375b7c37f95c0e99b28928ca213844b74
Statuses:
- legal/cla: Contributor License Agreement check
- ci/runbot: Odoo Test Suite
- ci/upgrade_enterprise: Test upgrades for enterprise master
- ci/template: Contact runbot team on discord for help.
- ci/style: Optional style check. Ignore it only if strictly necessary.
- ci/security: Required security check. Can only be ignored by security team.
- label
- odoo-dev:18.0-mail-fix-error-when-sending-mail-notifications-with-no-author-jbn
- head
- b08955380bbb6ba5eaf79df7125ee1ba81c10b88
- merged
- 9 months ago by Marketing, Thibault Delavallee (tde)
odoo/odoo | |
---|---|
18.0 | #194569 |
saas-18.1 | #194618 |
[FIX] mail: fix error when sending mail notifications with no author
There are instances where an email notification may not have an associated author. In the mail notification template, we forgot to check that the author exists before calling the _is_internal
on it. When the author is False
, the function generating the mail crashes as the _is_internal
function is undefined on a boolean variable.
To address this issue, we will ensure the existence of the author before invoking any methods defined in the res.users
model. This solution prevents errors and ensures the email template functions correctly.
see: #190390
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr