mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 16:46:12 +01:00
fix: don't confirm emails on HEAD request
outlook safelinks triggers page twice
This commit is contained in:
@@ -228,6 +228,10 @@ Controllers.confirmEmail = async (req, res) => {
|
|||||||
...opts,
|
...opts,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (req.method === 'HEAD') {
|
||||||
|
return renderPage();
|
||||||
|
}
|
||||||
try {
|
try {
|
||||||
if (req.loggedIn) {
|
if (req.loggedIn) {
|
||||||
const emailValidated = await user.getUserField(req.uid, 'email:confirmed');
|
const emailValidated = await user.getUserField(req.uid, 'email:confirmed');
|
||||||
|
|||||||
Reference in New Issue
Block a user