...
|
...
|
@@ -212,7 +212,18 @@ const bind = { |
|
|
sourceType: sourceType + '_bind'
|
|
|
});
|
|
|
|
|
|
return loginService.syncUserSession(result.data.uid, req, res).then(() => {
|
|
|
let uid = {
|
|
|
toString() {
|
|
|
return this.uid;
|
|
|
},
|
|
|
uid: result.data.uid,
|
|
|
sessionKey: result.data.session_key,
|
|
|
isValid() {
|
|
|
return this.uid && this.sessionKey;
|
|
|
}
|
|
|
};
|
|
|
|
|
|
return loginService.syncUserSession(uid, req, res, result.data.session_key).then(() => {
|
|
|
return {code: 200, message: result.message, data: {refer: refer}};
|
|
|
});
|
|
|
} else {
|
...
|
...
|
@@ -246,7 +257,18 @@ const bind = { |
|
|
sourceType: sourceType + '_relate'
|
|
|
});
|
|
|
|
|
|
return loginService.syncUserSession(result.data.uid, req, res).then(() => {
|
|
|
let uid = {
|
|
|
toString() {
|
|
|
return this.uid;
|
|
|
},
|
|
|
uid: result.data.uid,
|
|
|
sessionKey: result.data.session_key,
|
|
|
isValid() {
|
|
|
return this.uid && this.sessionKey;
|
|
|
}
|
|
|
};
|
|
|
|
|
|
return loginService.syncUserSession(uid, req, res, result.data.session_key).then(() => {
|
|
|
return {code: 200, message: result.message, data: {refer: refer}};
|
|
|
});
|
|
|
} else {
|
...
|
...
|
|