0
방법 여권 지역 전략 검사가 그렇게 때문에 왜 지역 전략을 수립하기 위해 같은 일을 확인할 수 있습니다 나는 또한 내 로컬 함수를 호출 할 수 있습니다여권
// passport involved code
app.post('/login',
passport.authenticate('local'),
function(req, res) {
// If this function gets called, authentication was successful.
// `req.user` contains the authenticated user.
res.redirect('/users/' + req.user.username);
});
사용자 지정 코드를 대 여권 지역 전략
// custom checking function
app.post('/login',
customfunctionhere,
function(req, res) {
// If this function gets called, authentication was successful.
// `req.user` contains the authenticated user.
res.redirect('/users/' + req.user.username);
});