#Bot can't read client.commands.get()

11 messages · Page 1 of 1 (latest)

inland anvil
#

I'm trying to let my bot run a command but I have came across a problem. On line 18 I get the following error: TypeError: Cannot read properties of undefined (reading 'get'). I have tried finding anything about this error on https://discordjs.guide/ and https://stackoverflow.com/ but I can't manage to find anything about this error. Could anyone help me out here?

dim grottoBOT
#

• What's your exact discord.js npm list discord.js and node node -v version?
• Post the full error stack trace, not just the top part!
• Show your code!
• Explain what exactly your issue is.
• Not a discord.js issue? Check out #useful-servers.

limber raptor
inland anvil
#

Hi, I fixed this issue, I did indeed forgot to define it. However I'm running into a new problem now.

My bot does respond to my !play message and executes the if statements on line 10 and 14 in my play.js file. However when I do !play songname my bot will not join the vc or play a song.

Do you maybe know how I could fix this?

pearl sleet
#

We don’t support either message commands nor TOS violations

inland anvil
#

may I ask what is against TOS with this ?

pearl sleet
#

YouTube TOS specifically, and by proxy also discord developer TOS

inland anvil
#

oooh I didnt know about this, i was just following a tutorial so thought it would be okay

rustic roostBOT
pearl sleet
#

Use an up-to-date guide instead of an outdated tutorial to get you up and running

inland anvil
#

thank you, is there a way to close this thread?