From a9798bb6910a8a97a3cc99d1e98059cd9218312f Mon Sep 17 00:00:00 2001 From: Ctrlcvs <1509167646@qq.com> Date: Mon, 24 Oct 2022 08:16:27 +0800 Subject: [PATCH] fix --- model/gsCfg.js | 10 ++++++++++ model/user.js | 3 ++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/model/gsCfg.js b/model/gsCfg.js index 202d415..bab097c 100644 --- a/model/gsCfg.js +++ b/model/gsCfg.js @@ -30,6 +30,16 @@ class GsCfg { fs.readFileSync(path + name + ".yaml", 'utf8') ) } + cpCfg (app, name) { + if (!fs.existsSync(`./plugins/${plugin}/config`)) { + fs.mkdirSync(`./plugins/${plugin}/config`) + } + + let set = `./plugins/${plugin}/config/${name}.yaml` + if (!fs.existsSync(set)) { + fs.copyFileSync(`./plugins/${plugin}/defSet/${app}/${name}.yaml`, set) + } + } async getMasterQQ(){ let qq; if(isV3){ diff --git a/model/user.js b/model/user.js index e87db32..22b5f89 100644 --- a/model/user.js +++ b/model/user.js @@ -87,6 +87,7 @@ export default class user { async multiSign(forumData) { let upData = [], message = ''; + await this.getCookie(this.e); for (let forum of forumData) { if (!(this.configSign.signlist.includes(forum.name))) { continue; @@ -94,7 +95,7 @@ export default class user { let res try { message += `**${forum.name}**\n` - res = await this.getData("userGameInfo", forum ) + res = await this.getData("userGameInfo", forum,false) await utils.sleepAsync(3000) //等几毫秒免得请求太频繁了 if (res?.data?.list?.length === 0 || !res?.data?.list) { message += `签到: 未绑定${forum.name}信息\n`;