can i get the solution for this
node:internal/errors:496
ErrorCaptureStackTrace(err);
^
TypeError [ERR_INVALID_ARG_TYPE]: The "emitter" argument must be an instance of EventEmitter. Received type string ('ready')
at new NodeError (node:internal/errors:405:5)
at eventTargetAgnosticAddListener (node:events:1032:11)
at node:events:987:5
at new Promise (<anonymous>)
at Client.once (node:events:967:10)
at Object.<anonymous> (C:\Users\Nishad\Desktop\Slash Commands\index.js:6:8)
at Module._compile (node:internal/modules/cjs/loader:1241:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1295:10)
at Module.load (node:internal/modules/cjs/loader:1091:32)
at Module._load (node:internal/modules/cjs/loader:938:12) {
code: 'ERR_INVALID_ARG_TYPE'
}
Node.js v20.7.0
25 Replies
- 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!Show your code
ihave doing coding
but ihave got an error
i didnt ask if you wrote code
i asked to show the code
ok
MediaFire
MediaFire
MediaFire is a simple to use free service that lets you put all your photos, documents, music, and video in a single place so you can access them anywhere and share them everywhere.
icant understand
what you talling
yes
ihave just started coding
icant upload file directly so ihave upload in media fire
sry wait
sir it not getting upload
MediaFire
MediaFire
MediaFire is a simple to use free service that lets you put all your photos, documents, music, and video in a single place so you can access them anywhere and share them everywhere.
node module
reset your token
and indeed
you call Client.once on the class
not on your constructed client
okk
??
the bot is not getting up
because you are calling Client.once on the class, not client.once
then what i need to add in there
you need to edit the way you call client
capitalization matters
you're calling it on the class
not on your
client
can you edit and snd
i cant uderstand that wolvinny said
iam noo good to trnslate english to my language so
ihave told
You have to change
Client.once
to client.once
Like he said, capitalization matters
I also won't spoonfeed you code so change it yourself
It's so simple
Backspace, cokk
also next time don't reveal your bot's token
okk bro
ihave just reset it
Reminder: don't share your config JSON