Hide hidden commands within specific command help

This commit is contained in:
7cc5c4f330d47060 2024-08-25 21:33:32 -04:00
parent f6b2365ccd
commit cb4aa5a818
Signed by: 7cc5c4f330d47060
SSH key fingerprint: SHA256:e+4tcZut1nBpe10PqjaO+Rvie0Q7W4qIvFzcUw+7riA

View file

@ -66,7 +66,7 @@ const printHelp = (c) => {
const printCmdHelp = (c) => { const printCmdHelp = (c) => {
const cmd = c.args[0] const cmd = c.args[0]
if (!cmds[cmd]) { if (!cmds[cmd] || (cmds[cmd].hidden && c.type !== 'console')) {
c.reply({ text: getMessage(c.lang, 'command.help.noCommand') }) c.reply({ text: getMessage(c.lang, 'command.help.noCommand') })
return return
} }