fix(service-party-app): 改为非阻塞方式连接 Message Router

将 connectAndRegisterToMessageRouter() 改为非阻塞调用,
不再使用 await 阻塞应用启动。

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
hailin 2025-12-28 23:34:10 -08:00
parent 28da7f6807
commit 4794cafdaa
1 changed files with 4 additions and 2 deletions

View File

@ -117,8 +117,10 @@ async function initServices() {
// 设置 IPC 处理器
setupIpcHandlers();
// 启动时自动连接并注册到 Message Router
await connectAndRegisterToMessageRouter();
// 启动时自动连接并注册到 Message Router (非阻塞)
connectAndRegisterToMessageRouter().catch((err) => {
console.error('Background connection failed:', err.message);
});
}
// 连接并注册到 Message Router