diff --git a/src/discord/monitor.ts b/src/discord/monitor.ts index 59b23cf32..78c5708ea 100644 --- a/src/discord/monitor.ts +++ b/src/discord/monitor.ts @@ -122,7 +122,8 @@ export async function monitorDiscordProvider(opts: MonitorDiscordOpts = {}) { if (message.author?.bot) return; if (!message.author) return; - const channelType = message.channel.type; + // Discord.js typing excludes GroupDM for message.channel.type; widen for runtime check. + const channelType = message.channel.type as ChannelType; const isGroupDm = channelType === ChannelType.GroupDM; const isDirectMessage = channelType === ChannelType.DM; const isGuildMessage = Boolean(message.guild);