Set VERP for the forward phase to the contact domain

This commit is contained in:
Adrià Casajús 2023-04-12 17:30:17 +02:00
parent 90cef3ca7d
commit d6ff744083
No known key found for this signature in database
GPG Key ID: F0033226A5AFC9B9
1 changed files with 2 additions and 1 deletions

View File

@ -945,10 +945,11 @@ def forward_email_to_mailbox(
envelope.rcpt_options,
)
contact_domain = get_email_domain_part(contact.reply_email)
try:
sl_sendmail(
# use a different envelope sender for each forward (aka VERP)
generate_verp_email(VerpType.bounce_forward, email_log.id),
generate_verp_email(VerpType.bounce_forward, email_log.id, contact_domain),
mailbox.email,
msg,
envelope.mail_options,