Skip to content
This repository has been archived by the owner on Dec 10, 2024. It is now read-only.

Commit

Permalink
Update volunteersServices.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
mauro8778 committed Dec 9, 2024
1 parent 35bfeda commit 3e1e7cd
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions src/services/volunteersServices.ts
Original file line number Diff line number Diff line change
Expand Up @@ -243,11 +243,17 @@ export const registerVolunteer = async (input: VolunteerRegistrationInput, userI

const inlinedHtml = juice(mailContent);

await mailService.sendEmail({
to: usuario.email,
subject: `Confirmación de inscripción: ${detalleOportunidad.description}`,
html: inlinedHtml
});
try {
await mailService.sendEmail({
to: usuario.email,
subject: `Confirmación de inscripción: ${detalleOportunidad.description}`,
html: inlinedHtml
});
} catch (error) {
console.error('Error sending email:', error);
throw new Error('Failed to send email');
}



return {
Expand Down

0 comments on commit 3e1e7cd

Please sign in to comment.