Skip to content

Commit

Permalink
fix: qq adapter upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
class-liu-fullstack committed Feb 2, 2025
1 parent 3d12cff commit d425c43
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/adapters/qq/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import {
GuildMessageEvent,
Intent,
Quotable,
Receiver,
} from 'qq-official-bot';
type QQMessageEvent = PrivateMessageEvent | GroupMessageEvent | GuildMessageEvent;
export type QQAdapter = typeof qq;
Expand Down Expand Up @@ -39,9 +40,10 @@ type QQConfig = {
};
const startBots = (configs: App.BotConfig<'qq'>[]) => {
for (const { private: isPrivate, group, public: isPublic, ...config } of configs) {
const botConfig: Bot.Config = {
const botConfig: Bot.Config<'websocket'> = {
logLevel: qq.app!.config.log_level as any,
...config,
mode: 'websocket',
intents: [
group && 'GROUP_AT_MESSAGE_CREATE',
isPrivate && 'C2C_MESSAGE_CREATE',
Expand Down

0 comments on commit d425c43

Please sign in to comment.