fix(core): resolve unhandled rejections on 403s and undefined channel guildId

- Safely resolve guildId in CommandHandler replyHandler and prefix formatters
- Catch MISSING_PERMISSIONS and COMMUNICATION_DISABLED (403) across MessageHandler send/reply/edit
- Prevent join failure in PlayerLifecycleMixin when text channel messages are denied
- Suppress sending error-replies into channels where the bot lacks send permissions
This commit is contained in:
NoLogicAlan committed 2026-10-24 01:00:30 +03:00
1 parent 7bd80e62f7
commit ec441ea20a
5 files changed
+91 -24

No files matched your search

+3 -3
View File
@@ -233,10 +233,10 @@ class Remix {
),
false,
{
icon_url: msg.channel.channel.guild?.icon
? `https://cdn.fluxer.app/icons/${msg.channel.channel.guild.id}/${msg.channel.channel.guild.icon}.webp`
icon_url: (msg.channel?.channel?.guild?.icon || msg.server?.icon)
? `https://cdn.fluxer.app/icons/${msg.channel?.channel?.guild?.id ?? msg.server?.id}/${msg.channel?.channel?.guild?.icon ?? msg.server?.icon}.webp`
: null,
title: msg.channel.channel.guild?.name ?? null,
title: msg.channel?.channel?.guild?.name ?? msg.server?.name ?? null,
}
);
};