Properly hide hidden commands from help

This commit is contained in:
Dragon Fire
2020-03-08 11:38:32 -04:00
parent 495d99ca5d
commit b33f551ac2
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -30,7 +30,7 @@ module.exports = class HelpCommand extends Command {
let cmdCount = 0; let cmdCount = 0;
for (const group of this.client.registry.groups.values()) { for (const group of this.client.registry.groups.values()) {
const owner = this.client.isOwner(msg.author); const owner = this.client.isOwner(msg.author);
const commands = group.commands.filter(cmd => owner ? true : !cmd.ownerOnly && !cmd.hidden); const commands = group.commands.filter(cmd => (owner ? true : !cmd.ownerOnly) && !cmd.hidden);
if (!commands.size) continue; if (!commands.size) continue;
cmdCount += commands.size; cmdCount += commands.size;
embed.addField( embed.addField(
+1 -1
View File
@@ -1,6 +1,6 @@
{ {
"name": "xiao", "name": "xiao",
"version": "112.2.5", "version": "112.2.6",
"description": "Your personal server companion.", "description": "Your personal server companion.",
"main": "Xiao.js", "main": "Xiao.js",
"scripts": { "scripts": {