From 13b9ccb060aeeaa523a1fcef7d174eaf559fd226 Mon Sep 17 00:00:00 2001 From: smallfawn <101914820+smallfawn@users.noreply.github.com> Date: Wed, 12 Apr 2023 18:12:08 +0800 Subject: [PATCH] Update gqcq.js --- gqcq.js | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/gqcq.js b/gqcq.js index e51da72..88d57a5 100644 --- a/gqcq.js +++ b/gqcq.js @@ -29,7 +29,7 @@ let userCount = 0; //--------------------------------------------------------- async function start() { - + await notice() console.log('\n============= 用户CK有效性验证 =============\n'); taskall = []; for (let user of userList) { @@ -490,6 +490,31 @@ function httpRequest(options, method) { }) }) } +async function notice() { + try { + let options = { + url: `https://ghproxy.com/https://raw.githubusercontent.com/smallfawn/api/main/notice.json`, + headers: {}, + } + //console.log(options); + let result = await httpRequest(options); + //console.log(result); + if (result) { + if ('notice' in result) { + DoubleLog(`${result.notice}`); + } else { + /* options.url = `https://ghproxy.com/https://raw.githubusercontent.com/smallfawn/api/main/notice.json` + result = await httpRequest(options); + if ('notice' in result) { + DoubleLog(`${result.notice}`); + } */ + } + } else { + } + } catch (e) { + console.log(e); + } +} function ts13() { return Math.round(new Date().getTime()).toString(); }