Whether a recipient has unsubscribed from all or from notification emails.
(email: string)
| 99 | |
| 100 | /** Whether a recipient has unsubscribed from all or from notification emails. */ |
| 101 | async function isUnsubscribed(email: string): Promise<boolean> { |
| 102 | const prefs = await getEmailPreferences(email) |
| 103 | return Boolean(prefs?.unsubscribeAll || prefs?.unsubscribeNotifications) |
| 104 | } |
| 105 | |
| 106 | /** |
| 107 | * Resolve the recipients that should receive a limit email, with all opt-outs |
no test coverage detected