mirror of
https://github.com/LLOneBot/LLOneBot.git
synced 2024-11-22 01:56:33 +00:00
🐛修复 hook ipc 时获取不到 eventName 导致其他插件 ipc 通信失败
This commit is contained in:
parent
104839f7ea
commit
e1e5c278b9
@ -46,7 +46,7 @@ export function startHook() {
|
||||
|
||||
ipcMain.emit = new Proxy(ipcMain.emit, {
|
||||
apply(target, thisArg, args: [eventName: string, ...args: any]) {
|
||||
if (args[2]?.eventName.startsWith('ns-LoggerApi')) {
|
||||
if (args[2]?.eventName?.startsWith('ns-LoggerApi')) {
|
||||
return target.apply(thisArg, args)
|
||||
}
|
||||
if (logHook) {
|
||||
|
@ -11,6 +11,10 @@ function isEmpty(value: unknown) {
|
||||
}
|
||||
|
||||
async function onSettingWindowCreated(view: Element) {
|
||||
console.log(view)
|
||||
if (!view){
|
||||
return
|
||||
}
|
||||
const config = await window.llonebot.getConfig()
|
||||
const ob11Config = { ...config.ob11 }
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user