moved email out to its own folder because i am using it twice

This commit is contained in:
2026-06-04 00:27:23 -05:00
parent a2eb02409e
commit ad8ef867eb
2 changed files with 13 additions and 11 deletions
+10
View File
@@ -0,0 +1,10 @@
import { SMTP_TOKEN, SMTP_USERNAME } from '$env/static/private'
import nodemailer from "nodemailer"
export const transporter = nodemailer.createTransport({
service: "Proton",
auth: {
user: SMTP_USERNAME,
pass: SMTP_TOKEN
},
authMethod: "PLAIN"
} as nodemailer.TransportOptions)
+3 -11
View File
@@ -2,7 +2,8 @@ export async function load({ }) {
console.log("sludge fest application") console.log("sludge fest application")
} }
import { SMTP_USERNAME } from '$env/static/private'
import { transporter } from "$lib/email"
export const actions = { export const actions = {
default: async ({ request }) => { default: async ({ request }) => {
let data = await request.formData(); let data = await request.formData();
@@ -87,13 +88,4 @@ export const actions = {
} }
} }
import { SMTP_TOKEN, SMTP_USERNAME } from '$env/static/private'
import nodemailer from "nodemailer"
const transporter = nodemailer.createTransport({
service: "Proton",
auth: {
user: SMTP_USERNAME,
pass: SMTP_TOKEN
},
authMethod: "PLAIN"
} as nodemailer.TransportOptions)