Revert "♻️ Improve email abstraction (#861)"

This reverts commit 93cc5b9b4d.
This commit is contained in:
Luke Vella 2023-09-15 15:32:37 +01:00
parent 93cc5b9b4d
commit 1199ca5c53
10 changed files with 141 additions and 738 deletions

View file

@ -1,19 +0,0 @@
import { EmailClient, SupportedEmailProviders } from "@rallly/emails";
const env = process.env["NODE" + "_ENV"];
export const emailClient = new EmailClient({
openPreviews: env === "developement",
useTestServer: env === "test",
provider: {
name: process.env.EMAIL_PROVIDER as SupportedEmailProviders,
},
mail: {
from: {
name: "Rallly",
address:
(process.env.NOREPLY_EMAIL as string) ||
(process.env.SUPPORT_EMAIL as string),
},
},
});