From 665e3c806faab1e33b7d5aa634b5edd840cb7fa3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=89=8B=E7=93=9C=E4=B8=80=E5=8D=81=E9=9B=AA?= Date: Wed, 22 May 2024 20:16:24 +0800 Subject: [PATCH] build: 1.4.0 - beta2 --- src/index.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/index.ts b/src/index.ts index cf878d47..2f39f1e5 100644 --- a/src/index.ts +++ b/src/index.ts @@ -28,7 +28,7 @@ InitWebUi(); const cmdOptions = program.opts(); // console.log(process.argv); checkVersion().then(async (remoteVersion: string) => { - const localVersion = JSON.parse(fsSync.readFileSync(path.join(__dirname, 'package.json')).toString()); + const localVersion = JSON.parse(fsSync.readFileSync(path.join(__dirname, 'package.json')).toString()).version; const localVersionList = localVersion.split('.'); const remoteVersionList = remoteVersion.split('.'); log('[NapCat] 当前版本:', localVersion); @@ -43,7 +43,7 @@ checkVersion().then(async (remoteVersion: string) => { logDebug('[NapCat] 当前已是最新版本'); return; }).catch((e) => { - logError('[NapCat] 检测更新失败'); + logError('[NapCat] 检测更新失败', e); }); // 不是很好待优化 let NapCat_OneBot11 = new NapCatOnebot11();