Added the ability for Corporate accounts to register without codes
This commit is contained in:
@@ -13,6 +13,8 @@ async function sendVerification(req: NextApiRequest, res: NextApiResponse) {
|
||||
const short = new ShortUniqueId();
|
||||
|
||||
if (req.session.user) {
|
||||
console.log("ME HERE");
|
||||
|
||||
const transport = prepareMailer("verification");
|
||||
const mailOptions = prepareMailOptions(
|
||||
{
|
||||
@@ -25,7 +27,8 @@ async function sendVerification(req: NextApiRequest, res: NextApiResponse) {
|
||||
"verification",
|
||||
);
|
||||
|
||||
await transport.sendMail(mailOptions);
|
||||
const result = await transport.sendMail(mailOptions);
|
||||
console.log(result);
|
||||
|
||||
res.status(200).json({ok: true});
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user