From 84836e26c1b1175bde1bd13c1b5ad7a0380691b8 Mon Sep 17 00:00:00 2001 From: Lamp Date: Sat, 1 Sep 2018 12:18:25 -0700 Subject: [PATCH] Fix coloRoles.pruneOrphanRoles() --- src/colorroles.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/colorroles.js b/src/colorroles.js index 5a940eb..1c75805 100755 --- a/src/colorroles.js +++ b/src/colorroles.js @@ -74,7 +74,7 @@ colorRoles.pruneOrphanRoles = async function() { // delete all color roles that var guild = dClient.defaultGuild || dClient.guilds.get(config.guildID); for (let role of guild.roles) { role = role[1]; - if (role.name.startsWith('[') && role.members.length == 0) + if (role.name.startsWith('[') && !role.members.size) await role.delete(); } };