diff --git a/fixbackend/notification/email/email_sender.py b/fixbackend/notification/email/email_sender.py index 4bac60cd..f74fa63a 100644 --- a/fixbackend/notification/email/email_sender.py +++ b/fixbackend/notification/email/email_sender.py @@ -64,7 +64,7 @@ async def send_email( subject: str, text: str, html: Optional[str], - unsubscribe: bool = False, + unsubscribe: bool = True, ) -> None: # pragma: no cover unsubscribe_url = "" @@ -89,7 +89,7 @@ def send_email() -> None: msg["From"] = "noreply@fix.security" msg["To"] = to if unsubscribe: - msg.add_header("List-Unsubscribe", f"{unsubscribe_url}") + msg.add_header("List-Unsubscribe", f"<{unsubscribe_url}>") msg.add_header("List-Unsubscribe-Post", "List-Unsubscribe=One-Click") plain_part = MIMEText(text, "plain")