debugging
This commit is contained in:
parent
d2a11a8004
commit
9acd645478
|
@ -30,7 +30,7 @@ const transporter = nodemailer.createTransport({
|
||||||
});
|
});
|
||||||
|
|
||||||
async function sendEmail(to: Address, subject: string, text: string) {
|
async function sendEmail(to: Address, subject: string, text: string) {
|
||||||
await transporter.sendMail({
|
return await transporter.sendMail({
|
||||||
from: adminAddress,
|
from: adminAddress,
|
||||||
to,
|
to,
|
||||||
subject,
|
subject,
|
||||||
|
|
|
@ -157,12 +157,14 @@ export async function createNewUser(
|
||||||
lastLogin: now,
|
lastLogin: now,
|
||||||
lastActive: now,
|
lastActive: now,
|
||||||
};
|
};
|
||||||
|
console.log("SENDING VERIFICATION EMAIL FROM SIGNUP");
|
||||||
await sendVerificationEmail({
|
await sendVerificationEmail({
|
||||||
name: input.name,
|
name: input.name,
|
||||||
uid: userId,
|
uid: userId,
|
||||||
email: input.email || "",
|
email: input.email || "",
|
||||||
token: email.token,
|
token: email.token,
|
||||||
});
|
});
|
||||||
|
console.log("GOT THROUGH AFTER VERIFICATION");
|
||||||
const user = await insertLingdocsUser(newUser);
|
const user = await insertLingdocsUser(newUser);
|
||||||
return user;
|
return user;
|
||||||
}
|
}
|
||||||
|
|
|
@ -190,6 +190,7 @@ const authRouter = (passport: PassportStatic) => {
|
||||||
});
|
});
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
console.error(e);
|
console.error(e);
|
||||||
|
console.error("EMAIL DIDN'T WORK 2");
|
||||||
return res.send("Invalid E-mail");
|
return res.send("Invalid E-mail");
|
||||||
}
|
}
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|
Loading…
Reference in New Issue