fix: suggested changes by itoh

This commit is contained in:
Skillz4Killz
2021-06-17 14:49:18 +00:00
committed by GitHub
parent efa4b21dd4
commit 10e1e8a034
2 changed files with 1 additions and 3 deletions

View File

@@ -20,7 +20,7 @@ export async function handleThreadListSync(data: DiscordGatewayPayload) {
);
eventHandlers.threadListSync?.(
new Collection(threads.map((t) => [t.id, t])),
new Collection(threads.map((t) => [t.id, channelToThread(t)])),
payload.members.map((member) => threadMemberModified(member)),
snowflakeToBigint(payload.guildId)
);

View File

@@ -110,8 +110,6 @@ export async function createDiscordenoChannel(data: Channel, guildId?: bigint) {
(Object.keys(rest) as (keyof typeof rest)[]).forEach((key) => {
eventHandlers.debug?.("loop", `Running forEach loop in createDiscordenoChannel function.`);
if (key === "threadMetadata") return;
props[key] = createNewProp(
CHANNEL_SNOWFLAKES.includes(key) ? (rest[key] ? snowflakeToBigint(rest[key] as string) : undefined) : rest[key]
);