Skip to content

Commit 1280521

Browse files
committed
fix(core): logout route with new passport
1 parent 5044b75 commit 1280521

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/controllers/main.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -192,9 +192,10 @@ mainController.l2AuthPost = function (req, res, next) {
192192
mainController.logout = function (req, res) {
193193
req.session.l2auth = null
194194
req.session.destroy(function () {
195-
req.logout()
196-
res.clearCookie('connect.sid')
197-
return res.redirect('/')
195+
req.logout(function () {
196+
res.clearCookie('connect.sid')
197+
return res.redirect('/')
198+
})
198199
})
199200
}
200201

0 commit comments

Comments
 (0)