Updated help command

This commit is contained in:
Christer Warén 2021-08-22 19:00:19 +03:00
parent 2fec81e84d
commit 7810f6fff8

View File

@ -32,9 +32,8 @@ module.exports = {
interaction.reply({ embeds: [embed] });
} else {*/
const categories = [];
let commandsToArray = Array.from(client.commands.values());
for (let i = 0; i < client.commands.size; i++) {
if (!categories.includes(commandsToArray[i].category)) categories.push(commandsToArray[i].category);
if (!categories.includes([...client.commands.values()][i].category)) categories.push([...client.commands.values()][i].category);
}
let commands = '';
for (let i = 0; i < categories.length; i++) {