This commit is contained in:
lxk0301
2021-05-17 20:55:16 +08:00
parent ae2fe381a3
commit 74c1a8ece7

View File

@@ -79,10 +79,12 @@ const JD_API_HOST = 'https://api.m.jd.com/';
} }
if (helpAuthor && $.authorCode) { if (helpAuthor && $.authorCode) {
console.log(`去帮助作者`) console.log(`去帮助作者`)
const helpRes = await help(code.shareCode, code.groupCode) for (let code of $.authorCode) {
if (helpRes && helpRes.data.respCode === 'SG209') { const helpRes = await help(code.shareCode, code.groupCode);
console.log(`助力次数已耗尽,跳出助力`) if (helpRes && helpRes.data.respCode === 'SG209') {
break; console.log(`助力次数已耗尽,跳出助力`)
break;
}
} }
} }
if (helpAuthor && $.authorCode2) { if (helpAuthor && $.authorCode2) {