Skip to content
This repository has been archived by the owner on Nov 19, 2019. It is now read-only.

Commit

Permalink
No longer rely on Collection instance for length property
Browse files Browse the repository at this point in the history
  • Loading branch information
kyogoi committed Oct 7, 2019
1 parent f7cc3b3 commit efccfd5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
const textChannel = bot.channels.get(channels.find((v) => v.voice_id == oldMember.voiceChannelID).text_id);
const permissions = textChannel.permissionOverwrites.find((v) => v.id == oldMember.id);

if (!voiceChannel.members.length) {
if (voiceChannel.members.array().length < 1) {
db.run('UPDATE channels SET set_to_purge = 1 WHERE voice_id = ?', [oldMember.voiceChannelID]);
}

Expand Down

0 comments on commit efccfd5

Please sign in to comment.