Skip to content

Commit

Permalink
backport/fix(GuildDelete): disconnect voice and cleanup GuildChannels
Browse files Browse the repository at this point in the history
  • Loading branch information
SpaceEEC committed Feb 5, 2018
1 parent 96904b1 commit 3df3741
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/client/actions/GuildDelete.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ class GuildDeleteAction extends Action {
};
}

for (const channel of guild.channels.values()) this.client.channels.delete(channel.id);
if (guild.voiceConnection) guild.voiceConnection.disconnect();

// Delete guild
client.guilds.delete(guild.id);
this.deleted.set(guild.id, guild);
Expand Down

0 comments on commit 3df3741

Please # to comment.