From 71d80c160f64a4d645faa9cc899944b991b76169 Mon Sep 17 00:00:00 2001 From: kaguramaisakuya <1657974606@qq.com> Date: Mon, 9 Oct 2023 22:04:09 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8Dhoyolab=E6=9C=AA=E5=85=AC?= =?UTF-8?q?=E5=BC=80=E6=97=B6=E6=8A=A5=E9=94=99=EF=BC=8C=E4=BC=98=E5=8C=96?= =?UTF-8?q?=E5=91=BD=E4=BB=A4=E6=AD=A3=E5=88=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitignore | 1 + plugins/genshin/apps/exchange.js | 2 +- plugins/genshin/apps/gcLog.js | 6 +++--- plugins/genshin/apps/material.js | 2 +- plugins/genshin/apps/mysNews.js | 2 +- plugins/genshin/apps/payLog.js | 4 ++-- plugins/genshin/apps/takeBirthdayPhoto.js | 2 +- plugins/genshin/model/mys/mysApi.js | 4 ++-- 8 files changed, 12 insertions(+), 11 deletions(-) diff --git a/.gitignore b/.gitignore index 8a24866..b94d123 100644 --- a/.gitignore +++ b/.gitignore @@ -136,6 +136,7 @@ data/ config/test/* !config/test/default.yaml logs/ +resources/ # Docker file redis diff --git a/plugins/genshin/apps/exchange.js b/plugins/genshin/apps/exchange.js index d45807c..419fbb9 100644 --- a/plugins/genshin/apps/exchange.js +++ b/plugins/genshin/apps/exchange.js @@ -17,7 +17,7 @@ export class exchange extends plugin { fnc: 'getCode' }, { - reg: '#(兑换码使用|cdk-u) .+', + reg: '^#(兑换码使用|cdk-u) .+', fnc: 'useCode' } ] diff --git a/plugins/genshin/apps/gcLog.js b/plugins/genshin/apps/gcLog.js index 237a772..0c81ba2 100644 --- a/plugins/genshin/apps/gcLog.js +++ b/plugins/genshin/apps/gcLog.js @@ -20,15 +20,15 @@ export class gcLog extends plugin { fnc: 'logUrl' }, { - reg: '#txt日志文件导入记录', + reg: '^#txt日志文件导入记录$', fnc: 'logFile' }, { - reg: '#xlsx文件导入记录', + reg: '^#xlsx文件导入记录$', fnc: 'logXlsx' }, { - reg: '#json文件导入记录', + reg: '^#json文件导入记录$', fnc: 'logJson' }, { diff --git a/plugins/genshin/apps/material.js b/plugins/genshin/apps/material.js index 64913c7..2db9410 100644 --- a/plugins/genshin/apps/material.js +++ b/plugins/genshin/apps/material.js @@ -14,7 +14,7 @@ export class material extends plugin { priority: 500, rule: [ { - reg: '#*(.*)(突破|材料|素材)$', + reg: '^#*(.*)(突破|材料|素材)$', fnc: 'material' } ] diff --git a/plugins/genshin/apps/mysNews.js b/plugins/genshin/apps/mysNews.js index 850fc17..83e0641 100644 --- a/plugins/genshin/apps/mysNews.js +++ b/plugins/genshin/apps/mysNews.js @@ -27,7 +27,7 @@ export class mysNews extends plugin { fnc: 'mysUrl' }, { - reg: '#*原(石|神)(预估|盘点)$', + reg: '^#*原(石|神)(预估|盘点)$', fnc: 'ysEstimate' }, { diff --git a/plugins/genshin/apps/payLog.js b/plugins/genshin/apps/payLog.js index 9d4fa17..83cadf0 100644 --- a/plugins/genshin/apps/payLog.js +++ b/plugins/genshin/apps/payLog.js @@ -22,7 +22,7 @@ export class payLog extends plugin { fnc: 'payLog' }, { - reg: '^#?更新(充值|消费)(记录|统计)', + reg: '^#?更新(充值|消费)(记录|统计)$', fnc: 'updatePayLog' }, { @@ -31,7 +31,7 @@ export class payLog extends plugin { fnc: 'getAuthKey' }, { - reg: '^#?(充值|消费)(记录|统计)帮助', + reg: '^#?(充值|消费)(记录|统计)帮助$', fnc: 'payLogHelp' } ] diff --git a/plugins/genshin/apps/takeBirthdayPhoto.js b/plugins/genshin/apps/takeBirthdayPhoto.js index 00be7c7..b834236 100644 --- a/plugins/genshin/apps/takeBirthdayPhoto.js +++ b/plugins/genshin/apps/takeBirthdayPhoto.js @@ -11,7 +11,7 @@ export class takeBirthdayPhoto extends plugin { priority: 5000, rule: [ { - reg: '#?(留影(叙佳期)?|((领)?((角色)?生日)(卡)?))$', + reg: '^#?(留影(叙佳期)?|((领)?((角色)?生日)(卡)?))$', fnc: 'birthdaystar' } ] diff --git a/plugins/genshin/model/mys/mysApi.js b/plugins/genshin/model/mys/mysApi.js index 2507ffb..b54e181 100644 --- a/plugins/genshin/model/mys/mysApi.js +++ b/plugins/genshin/model/mys/mysApi.js @@ -133,9 +133,9 @@ export default class MysApi { return false } - if (res.retcode !== 0 && this.option.log) { + /* if (res.retcode !== 0 && this.option.log) { logger.debug(`[米游社接口][请求参数] ${url} ${JSON.stringify(param)}`) - } + } */ res.api = type