From 95edd74d9fec84cbf49b1c30ae055f0d636e6ffa Mon Sep 17 00:00:00 2001
From: 1sonhador <1sonhador@gmail.com>
Date: Wed, 1 Jul 2026 09:56:38 +0100
Subject: [PATCH] fix: send clean invoice-only emails to avoid MailChannels
spam blocks
Stop relaying the original RFC822 (SendGrid headers, Fwd: subject, etc.).
Send a new message with PDF/XML/ZIP attachments and minimal metadata body.
---
admin-ui/src/pages/Accounts.tsx | 2 +-
src/forwarder/email/smtp_client.py | 110 +++++++++++--------------
src/forwarder/services/sync_service.py | 11 ++-
tests/test_smtp_forward.py | 71 +++++++---------
4 files changed, 86 insertions(+), 108 deletions(-)
diff --git a/admin-ui/src/pages/Accounts.tsx b/admin-ui/src/pages/Accounts.tsx
index 967f7a8..b464a79 100644
--- a/admin-ui/src/pages/Accounts.tsx
+++ b/admin-ui/src/pages/Accounts.tsx
@@ -131,7 +131,7 @@ function AccountModal({