mirror of
https://github.com/discordeno/discordeno.git
synced 2026-09-17 08:47:22 +00:00
fix: channel create guild id was missing
This commit is contained in:
@@ -1,8 +1,10 @@
|
||||
import type { Bot, DiscordChannel, DiscordGatewayPayload } from '../../index.js'
|
||||
|
||||
export async function handleChannelCreate(bot: Bot, payload: DiscordGatewayPayload, shardId: number): Promise<void> {
|
||||
const data = payload.d as DiscordChannel
|
||||
const channel = bot.transformers.channel(bot, {
|
||||
channel: payload.d as DiscordChannel,
|
||||
channel: data,
|
||||
guildId: data.guild_id ? bot.transformers.snowflake(data.guild_id) : undefined,
|
||||
})
|
||||
|
||||
bot.events.channelCreate?.(channel)
|
||||
|
||||
Reference in New Issue
Block a user