Skip to content

Commit

Permalink
Merge PR #1486 into 16.0
Browse files Browse the repository at this point in the history
Signed-off-by yajo
  • Loading branch information
OCA-git-bot committed Nov 5, 2024
2 parents 07b9c3c + d298684 commit 5539dcb
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions mail_show_follower/models/mail_mail.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,14 +72,16 @@ def _send(self, auto_commit=False, raise_exception=False, smtp_session=None):
show_in_cc_recipients = recipients._filter_shown_in_cc(show_internal_users)
if len(show_in_cc_recipients) <= 1:
continue

langs = (
mail.notification_ids.res_partner_id.mapped("lang")
lang = (
mail.notification_ids.res_partner_id[:1].lang
or mail.author_id.lang
or company.partner_id.lang
or "en_US"
)
final_cc = mail.with_context(lang=langs[0])._build_cc_text(
show_in_cc_recipients
final_cc = (
mail.with_context(lang=lang)
.with_company(company)
._build_cc_text(show_in_cc_recipients)
)
mail.body_html = final_cc + mail.body_html

Expand Down

0 comments on commit 5539dcb

Please sign in to comment.