#How to stop the bot from fetching slashcommand subgroups as commands?

1 messages · Page 1 of 1 (latest)

cold mesa
#
    async def help(self, ctx):
        pages = []
        prefix = "/"
        em = discord.Embed(color=discord.Color.blurple(),
                            description=f"Use the pagination to check the specific module's commands!\nList of modules:")
        em.set_author(name="Skyblock Insurance", icon_url="https://cdn.discordapp.com/app-icons/946690242541420624/eba76b325390ea01e9a9178a77375ebb.webp")
        for cog in self.bot.cogs:
            em.add_field(name=cog, value="\u200b")
        em.set_footer(text=f"Made by team h.")
        pages.append(em)
        for cog in self.bot.cogs:
            cog_emb = discord.Embed(color=discord.Color.blurple(), description=f"**{cog.capitalize()}'s commands:**")
            cog_emb.set_author(name="Skyblock Insurance", icon_url="https://cdn.discordapp.com/app-icons/946690242541420624/eba76b325390ea01e9a9178a77375ebb.webp")
            for command in self.bot.get_cog(cog).walk_commands():
                if command.full_parent_name:
                    command_name = command.full_parent_name + " " + command.name
                else:
                    command_name = command.name
                cog_emb.add_field(name=f"{prefix}{command_name}",
                value=f"""
                ```{command.description}```""")
            pages.append(cog_emb)

This code works fine enough with the only wrong thing being that it fetches subgroups of slash commands as commands too, which is quite annoying
Is there any way to fix this? I am looking through the docs rn to find anything

#

/donations roles is the subgroup

cold mesa
cold mesa
#

doing it rn

#

omfg

#

open source sbi bot is the biggest piece of shit I have ever seen

#

and nowhere close to this

#

@cold mesa

cold mesa
cold mesa
#

yk?

#

'Skyblock insurance'

#

yea

#

nice open source help command "I stole"

#

I love it how my work isnt even acknowledged

#

as mine

#

lmfao

cold mesa
cold mesa
#

making this for them?

cold mesa
#

"Just learn it, It aint even your bot lol its the open source sbi bot"

#

I legit wrote that

#

ask @cold mesa

#

or @normal wasp

#

or @fleet mica

cold mesa
#

I beleive u mate i just asked lol

normal wasp
cold mesa
#

hello tim

normal wasp
#

wait this is the guy from sbi

cold mesa
#

no

#

he isnt in sbi

#

else I wouldnt even talk to him

normal wasp
#

yea he is

cold mesa
#

bru lmao

#

wait he is

#

i just talked to timnoot

#

it didnt show in mutual servers

#

lol

normal wasp
cold mesa
#

thats discord being shit

normal wasp
cold mesa
#

I said your token/sessionid can be stolen from joining a discord server

#

no lol

cold mesa
#

it cant

#

'a server'

normal wasp
#

neither can it be stolen by joining a discord server lol

cold mesa
#

it can

#

How tho

#

lmfao

normal wasp
cold mesa
#

ok fr stop pinging me

normal wasp
#

ur pinging me aswell?

#

but explain

cold mesa
cold mesa
normal wasp
#

u pinged me 9 times in 2 servers

cold mesa
#

nice 6 times

viscid warren
cold mesa
#

friend already helped but tyty