Merge pull request #65 from 9qz/main

Fix guild_id being undefined on MongoCacheStream
This commit is contained in:
Flam3rboy 2021-05-11 15:11:27 +02:00 committed by GitHub
commit afa30bd07a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -56,7 +56,7 @@ export async function dispatch(this: WebSocket, document: Event, { eventStream,
} }
if (document.event === "GUILD_CREATE") { if (document.event === "GUILD_CREATE") {
guilds.push(document.guild_id); guilds.push(document.data.id);
eventStream.changeStream(getPipeline.call(this, guilds)); eventStream.changeStream(getPipeline.call(this, guilds));
} else if (document.event === "GUILD_DELETE") { } else if (document.event === "GUILD_DELETE") {
guilds.remove(document.guild_id); guilds.remove(document.guild_id);