fix: get rid of type errors for now (#2113)

This commit is contained in:
Yuzu
2022-03-18 04:19:55 +00:00
committed by GitHub
parent 44f02d0c65
commit 33bafd1f6c
10 changed files with 37 additions and 28 deletions
+2 -1
View File
@@ -1,9 +1,10 @@
import type { Bot } from "../../bot.ts";
import type { Guild } from "../../transformers/guild.ts";
import { DiscordGatewayPayload, DiscordGuild } from "../../types/discord.ts";
export function handleGuildLoaded(bot: Bot, data: DiscordGatewayPayload, shardId: number) {
const payload = data.d as DiscordGuild;
const guild = bot.transformers.guild(bot, { guild: payload, shardId });
bot.events.guildLoaded(bot, guild);
bot.events.guildLoaded(bot, guild as Guild);
}