diff --git a/manifest.json b/manifest.json index dead8693..87e7588a 100644 --- a/manifest.json +++ b/manifest.json @@ -4,7 +4,7 @@ "name": "NapCatQQ", "slug": "NapCat.Framework", "description": "高性能的 OneBot 11 协议实现", - "version": "2.2.9", + "version": "2.2.10", "icon": "./logo.png", "authors": [ { diff --git a/package.json b/package.json index 4a5550f9..10ff32fa 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "napcat", "private": true, "type": "module", - "version": "2.2.9", + "version": "2.2.10", "scripts": { "build:framework": "vite build --mode framework", "build:shell": "vite build --mode shell", diff --git a/src/common/framework/napcat.ts b/src/common/framework/napcat.ts index 0adf2d11..61a4eed3 100644 --- a/src/common/framework/napcat.ts +++ b/src/common/framework/napcat.ts @@ -2,7 +2,7 @@ import path, { dirname } from 'path'; import { fileURLToPath } from 'url'; import fs from 'fs'; -export const napcat_version = '2.2.9'; +export const napcat_version = '2.2.10'; export class NapCatPathWrapper { binaryPath: string; diff --git a/src/onebot/api/msg.ts b/src/onebot/api/msg.ts index d46a9d23..e7a42e87 100644 --- a/src/onebot/api/msg.ts +++ b/src/onebot/api/msg.ts @@ -59,6 +59,7 @@ export class OneBotMsgApi { rawToOb11Converters: RawToOb11Converters = { textElement: async element => { + console.log(element); if (element.atType === AtType.notAt) { let text = element.content; if (!text.trim()) { @@ -707,7 +708,7 @@ export class OneBotMsgApi { const msgSegments = (await Promise.all(msg.elements.map( async (element) => { for (const key in element) { - if (keyCanBeParsed(key, this.rawToOb11Converters) && this.rawToOb11Converters[key]) { + if (keyCanBeParsed(key, this.rawToOb11Converters) && element[key]) { return await this.rawToOb11Converters[key]?.( // eslint-disable-next-line // @ts-ignore diff --git a/src/webui/ui/NapCat.ts b/src/webui/ui/NapCat.ts index 9deb9cdd..2b90e1c4 100644 --- a/src/webui/ui/NapCat.ts +++ b/src/webui/ui/NapCat.ts @@ -30,7 +30,7 @@ async function onSettingWindowCreated(view: Element) { SettingItem( 'Napcat', undefined, - SettingButton('V2.2.9', 'napcat-update-button', 'secondary'), + SettingButton('V2.2.10', 'napcat-update-button', 'secondary'), ), ]), SettingList([ diff --git a/static/assets/renderer.js b/static/assets/renderer.js index f88e5e08..a536ff1e 100644 --- a/static/assets/renderer.js +++ b/static/assets/renderer.js @@ -164,7 +164,7 @@ async function onSettingWindowCreated(view) { SettingItem( 'Napcat', void 0, - SettingButton("V2.2.9", "napcat-update-button", "secondary") + SettingButton("V2.2.10", "napcat-update-button", "secondary") ) ]), SettingList([