Skip to content

Commit 6baf587

Browse files
authored
Update user.js
1 parent ea5fde6 commit 6baf587

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

toolkit/back/routes/user.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -211,9 +211,9 @@ router.post('/', isNotLoggedIn, async (req, res, next) => { // POST /user/
211211
});
212212

213213
router.post('/logout', isLoggedIn, (req, res) => {
214-
req.logout();
215-
req.session.destroy();
216-
res.send('ok');
214+
req.logout(() => {
215+
res.send('ok');
216+
});
217217
});
218218

219219
router.patch('/nickname', isLoggedIn, async (req, res, next) => {

0 commit comments

Comments
 (0)