diff --git a/commands/config.js b/commands/config.js index 1942546..964bbb8 100644 --- a/commands/config.js +++ b/commands/config.js @@ -652,10 +652,10 @@ module.exports = { }) } let action = ''; + let roleId = interaction.customId.split('-')[2]; if (interaction.customId.split('-')[1]=='yes') { - let role = interaction.customId.split('-')[2]; action = 'removed'; - client.dbo.collection("guilds").updateOne({"server.serverID":GuildDB.serverID}, {$pull: {"server.botAdminRoles": role}}, function(err, res) { + client.dbo.collection("guilds").updateOne({"server.serverID":GuildDB.serverID}, {$pull: {"server.botAdminRoles": roleId}}, function(err, res) { if (err) return client.sendInternalError(interaction, err); }); } else if (interaction.customId.split('-')[1]=='no') action = 'kept'; diff --git a/package.json b/package.json index 5a3dc41..700891b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "dayz-armbands", - "version": "6.0.2", + "version": "6.0.3", "description": "A General Purpose Discord Bot for DayZ Servers.", "main": "index.js", "nodemonConfig": {