Skip to content

Commit

Permalink
Add the logout callback to prevent exception.
Browse files Browse the repository at this point in the history
  • Loading branch information
hcyuser committed Aug 9, 2023
1 parent c4f607f commit e95544b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/auth/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ authRouter.get('/logout', function (req, res) {
if (config.debug && req.isAuthenticated()) {
logger.debug('user logout: ' + req.user.id)
}
req.logout()
req.logout(()=>{
logger.debug('Please implement logout callback here.')
})
res.redirect(config.serverURL + '/')
})

0 comments on commit e95544b

Please sign in to comment.