Skip to content

Commit 9e2c9ba

Browse files
committed
1 parent 3b4c21b commit 9e2c9ba

1 file changed

Lines changed: 10 additions & 9 deletions

File tree

‎Task/txnews.js‎

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11

22
/*
3-
更新时间: 2020-09-27 10:10
3+
更新时间: 2020-10-16 20:10
44
55
腾讯新闻签到修改版,可以自动阅读文章获取红包,该活动为瓜分百万现金挑战赛,针对幸运用户参与
66
@@ -188,13 +188,14 @@ function activity() {
188188
return new Promise((resolve, reject) => {
189189
setTimeout(()=>{
190190
$.get({url:`${TX_HOST}user/activity/get?isJailbreak=0&${token}`, headers: {Cookie:cookieVal}}, (error,response, data) =>{
191-
if (error) {
192-
$.msg("获取活动Id失败‼️", "", error)
193-
} else {
194-
let obj = JSON.parse(data)
195-
actid = obj.data.activity.id
196-
console.log(` 您的活动ID为: `+actid+"\n")
197-
}
191+
try{
192+
let obj = JSON.parse(data)
193+
actid = obj.data.activity.id
194+
console.log(` 您的活动ID为: `+actid+"\n")
195+
} catch(error){
196+
$.msg("获取活动ID失败,详情请看日志","","")
197+
console.log("活动ID日志:"+ data)
198+
}
198199
resolve()
199200
})
200201
},s)
@@ -283,7 +284,7 @@ function Redpack() {
283284
redpackres = `【阅读红包】到账`+redpacks+`元 🌷\n`
284285
$.log("阅读红包到账"+redpacks+"元\n")
285286
}
286-
else if (rcash.ret == 0&&redpacks>0){
287+
else if (rcash.ret == 0&& redpacks >0){
287288
redpackres = `【视频红包】到账`+redpacks+`元 🌷\n`
288289
$.log("视频红包到账"+redpacks+"元\n")
289290
}

0 commit comments

Comments
 (0)