Problems with a command

I'm creating a poll system, this command will have subcommands and stuff. The problem it's that when I test the command, my bot throws me the error in the chat saying "The application did not respond", but when I check my terminal there is no error. Before putting the subcommands, the bot was sending the responses correctly but now it doesn't, why? Please help me with this. Here is the code: https://pastecode.io/s/gko3e2ux If y'all need anything, let me know and I'll send it.
Poll System (gko3e2ux) - PasteCode.io
Here is the code of the poll system I have.
6 Replies
d.js toolkit
d.js toolkit16mo ago
- What's your exact discord.js npm list discord.js and node node -v version? - Not a discord.js issue? Check out #other-js-ts. - Consider reading #how-to-get-help to improve your question! - Explain what exactly your issue is. - Post the full error stack trace, not just the top part! - Show your code! - Issue solved? Press the button!
ShompiFlen
ShompiFlen15mo ago
can you give an example of you running this command and what happens i mean, obviously nothing happens since your bot is not responding to it but which command are you trying to run?
clapii 𓆰𓆪
clapii 𓆰𓆪OP15mo ago
I do something like this: /poll channels set type: Channel where polls will be sent channel: #example Then, the message "The app did not respond" appears, the same exact thing it's with the /polls roles set but I still don't know why this problem happens /polls channels set /polls roles set anything?
ShompiFlen
ShompiFlen15mo ago
so there is no error in the console you say okay the first issue I see is this const subcommandName = interaction.options.getSubcommand(); you are not supposed to get the subcommand here, but the subcommandGroup
ShompiFlen
ShompiFlen15mo ago
Discord.js
Discord.js is a powerful node.js module that allows you to interact with the Discord API very easily. It takes a much more object-oriented approach than most other JS Discord libraries, making your bot's code significantly tidier and easier to comprehend.
ShompiFlen
ShompiFlen15mo ago
fix that one first because then you are checking for a subcommand "channels" that doesnt exist, because that is the name of your subcommand group
Want results from more Discord servers?
Add your server