passport js missing credentials

前端 未结 7 837
夕颜
夕颜 2020-12-31 02:03

Been working on this for a few hours now, pretty frustrating...

router.post(\'/\',
passport.authenticate(\'local-signup\', function(err, user, info) {
    co         


        
7条回答
  •  陌清茗
    陌清茗 (楼主)
    2020-12-31 02:24

    In Router.post:

    router.post('/', passport.authenticate('local-signup', {
        successRedirect: '/dashboad',
        failureRedirect: '/',
        badRequestMessage: 'Your message you want to change.', //missing credentials
        failureFlash: true
    }, function(req, res, next) {
    ...
    

提交回复
热议问题