mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 16:46:12 +01:00
fix: clear interstitial data if there are no additional interstitials on abort
This commit is contained in:
@@ -218,6 +218,7 @@ authenticationController.registerAbort = async (req, res) => {
|
|||||||
|
|
||||||
const { interstitials } = await user.interstitials.get(req, req.session.registration);
|
const { interstitials } = await user.interstitials.get(req, req.session.registration);
|
||||||
if (!interstitials.length) {
|
if (!interstitials.length) {
|
||||||
|
delete req.session.registration;
|
||||||
return res.redirect(nconf.get('relative_path') + (req.session.returnTo || '/'));
|
return res.redirect(nconf.get('relative_path') + (req.session.returnTo || '/'));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user