...
|
...
|
@@ -29,7 +29,10 @@ const checkAPI = (req, res) => { |
|
|
};
|
|
|
|
|
|
const passwordRequired = (req, res, next) => {
|
|
|
if (req.session.type === 'needCaptcha' && req.body.loginType === 'password') {
|
|
|
|
|
|
// 默认账户密码登录需要验证码
|
|
|
//if (req.session.type === 'needCaptcha' && req.body.loginType === 'password') {
|
|
|
if (req.body.loginType === 'password') {
|
|
|
return requiredAPI(req, res, next);
|
|
|
} else {
|
|
|
return next();
|
...
|
...
|
|