Skip to content

Commit

Permalink
use kubecon.devzero.io for emails (#22)
Browse files Browse the repository at this point in the history
  • Loading branch information
cmiller01 authored Dec 11, 2024
1 parent 104721b commit 297f19b
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
4 changes: 2 additions & 2 deletions src/app/actions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ export async function submitForm(formData: FormData) {

// Send email (existing functionality)
await resend.emails.send({
from: 'kubecon@devzero.io',
from: 'kubecon@kubecon.devzero.io',
to: email,
subject: 'Welcome to KubeCon!',
html: `<p>Hello ${name},</p><p>Welcome to KubeCon! We're excited to have you join us.</p>`,
Expand All @@ -54,4 +54,4 @@ export async function submitForm(formData: FormData) {
console.error('Error in submitForm:', error)
return { error: 'Failed to submit form' }
}
}
}
5 changes: 2 additions & 3 deletions src/app/api/submit-landing-form/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,10 @@ export async function POST(request: Request) {
// Send email with the rendered HTML
console.log('Attempting to send email')
const emailResult = await resend.emails.send({
from: 'DevZero <no-reply@devzero.io>',
from: 'DevZero <no-reply@kubecon.devzero.io>',
to: email,
subject: 'Welcome to DevZero @ KubeCon 2024!',
replyTo: 'debo@devzero.io',
bcc: '21418179@bcc.hubspot.com',
html: emailHtml,
})

Expand All @@ -88,4 +87,4 @@ export async function POST(request: Request) {
console.error('Error in submitForm:', error)
return NextResponse.json({ error: 'Internal server error', details: error }, { status: 500 })
}
}
}
4 changes: 2 additions & 2 deletions src/app/api/submit-lego-sweepstakes/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ export async function POST(request: Request) {
// Send email with the rendered HTML
console.log('Attempting to send email')
const emailResult = await resend.emails.send({
from: 'DevZero <no-reply@devzero.io>',
from: 'DevZero <no-reply@kubecon.devzero.io>',
to: formData.email,
subject: 'Your LEGO Minifigure from DevZero!',
replyTo: 'debo@devzero.io',
Expand All @@ -94,4 +94,4 @@ export async function POST(request: Request) {
{ status: 500 }
)
}
}
}

0 comments on commit 297f19b

Please sign in to comment.