MCPcopy Create free account
hub / github.com/Semporia/Scripts / doubleRandomFood

Function doubleRandomFood

jd_joy_steal.js:423–441  ·  view source on GitHub ↗
(friendPin)

Source from the content-addressed store, hash-verified

421//收集好友狗粮,已实现分享可得双倍狗粮功能
422//①分享
423function doubleRandomFood(friendPin) {
424 return new Promise(resolve => {
425 $.get(taskUrl('doubleRandomFood', friendPin), (err, resp, data) => {
426 try {
427 if (err) {
428 console.log('\n京东宠汪汪: API查询请求失败 ‼️‼️')
429 throw new Error(err);
430 } else {
431 // console.log('分享', JSON.parse(data))
432 // $.appGetPetTaskConfigRes = JSON.parse(data);
433 }
434 } catch (e) {
435 $.logErr(e, resp);
436 } finally {
437 resolve();
438 }
439 })
440 })
441}
442//②领取双倍狗粮
443function getRandomFood(friendPin) {
444 return new Promise(resolve => {

Callers 1

stealFriendsFoodFunction · 0.85

Calls 4

taskUrlFunction · 0.70
getMethod · 0.45
logMethod · 0.45
logErrMethod · 0.45

Tested by

no test coverage detected