Authored by 陈峰

Merge branch 'hotfix/login' into 'grey'

第三方登录bug



See merge request !207
... ... @@ -295,6 +295,8 @@ const wechat = {
const sina = {
login: (req, res, next) => {
// 设置为原链接标识originalUrl
req.session.originalUrl = 'true';
req.session.authState = uuid.v4();
return passport.authenticate('sina', {
state: req.session.authState
... ... @@ -321,6 +323,8 @@ const sina = {
const qq = {
login: (req, res, next) => {
// 设置为原链接标识originalUrl
req.session.originalUrl = 'true';
req.session.authState = uuid.v4();
return passport.authenticate('qq', {
state: req.session.authState
... ... @@ -348,6 +352,8 @@ const qq = {
const alipay = {
login: (req, res, next) => {
// 设置为原链接标识originalUrl
req.session.originalUrl = 'true';
return passport.authenticate('alipay')(req, res, next);
},
callback: (req, res, next) => {
... ...