Repository navigation
[TAS-6838] 💬 Send system emails as 3ook.com 店員 - #1535
Conversation
There was a problem hiding this comment.
🟢 Approval recommended
No objective defects were found—the RFC 2047 encoded sender, parameter removal, and test and snapshot updates were all verified as internally consistent, with the only observation being a clearly intentional, non-blocking sender change.
No open issues 🎉
What changed in this PR
This PR changes the sender identity of system emails so the "From" display name reads 3ook.com 店員 ("3ook.com clerk"). Because AWS SES only accepts ASCII in the Source field, the non-ASCII display name is emitted as an RFC 2047 encoded-word (=?UTF-8?B?<base64>?=). It also consolidates all outgoing templated emails onto this single SYSTEM_EMAIL sender by dropping the per-call source override — including the two sales-notification emails that previously sent from "3ook.com Sales Team" <sales@3ook.com>, which now send from cs@3ook.com as well.
Changes:
- Encode
SYSTEM_EMAIL's non-ASCII display name as an RFC 2047 encoded-word so SES accepts it. - Remove the
sourceparameter fromsendSESTemplateEmailand always useSYSTEM_EMAILasSource, dropping thesource: SALES_EMAILoverrides on the auto-deliver and manual sales emails. - Update the unit test assertion and all snapshot
Sourcevalues to the encoded sender.
| File | Description |
|---|---|
src/constant/index.ts |
Builds SYSTEM_EMAIL as an RFC 2047 base64 encoded-word for the 3ook.com 店員 display name, with an explanatory comment. |
src/util/ses.ts |
Removes the optional source param/override and hardcodes Source: SYSTEM_EMAIL, routing all emails (including sales notifications) through the system sender. |
test/unit/ses-emails.test.ts |
Updates the explicit params.Source assertion to the encoded sender. |
test/unit/__snapshots__/ses-emails.test.ts.snap |
Updates all snapshot Source values to the encoded sender. |
Note (non-blocking, not filed as a comment since it is clearly intentional per the explicit line removals and snapshot updates): dropping source: SALES_EMAIL means the two sales-notification emails now send from cs@3ook.com instead of sales@3ook.com. If sales@3ook.com is relied on for recipient-side filtering or deliverability, confirm that consolidation is desired.
Review effort: Balanced
No description provided.