请教下,这个问题 TypeError: undefined is not a function
User.get(req.body.user,function(err,user) //总是报这行的错误
{
if(!user){
return err;
res.redirect(‘/’);
}
if(user.password!=password)
{
return err;
res.redirect(‘/’);
}
req.session.user=user;
req.flash(‘success’,’登陆成功’);
res.redirect(‘/’);
});
});