TASK22224: nextauth notify try-catch micro-refactor

This commit is contained in:
2026-03-24 06:18:35 +00:00
parent fe394f3fa8
commit 7c0dc30b1a
2 changed files with 42 additions and 4 deletions
+6 -4
View File
@@ -139,8 +139,8 @@ const authOptions = (req, res) => {
process.env.NOTIFY_API_KEY
);
await notifyClient
.sendEmail(
try {
await notifyClient.sendEmail(
effectiveLocale === "cy"
? templateIdcy
: templateId,
@@ -149,8 +149,10 @@ const authOptions = (req, res) => {
personalisation,
reference
}
)
.catch((error) => consoleLogger(error));
);
} catch (error) {
consoleLogger(error);
}
}
})
],