bot.guilds.get("ID").members.get("ID") says undefined
When i try to use this it just returns "undefined" this worked before in the older versions, has this changed or what?
14 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!
- ✅
Marked as resolved by staffDoes this bot even when you start it up get all of servers members/channels in the first place?
I just checked, the bot has cached server it is in, and the channels and im getting error "bot.channels.get("ID")" as undefined even if it is cached
Unknown User•15mo ago
Message Not Public
Sign In & Join Server To View
typing in "console.log(bot.channels)" shows that it is cached
Unknown User•15mo ago
Message Not Public
Sign In & Join Server To View
and bot.channels.cache appears as undefined here it says its d.js 1.14.0
Unknown User•15mo ago
Message Not Public
Sign In & Join Server To View
keyboard messed up, when i do console.log(bot.channels.cache) it says shows undefined
Unknown User•15mo ago
Message Not Public
Sign In & Join Server To View
This is a old code from 2019, bot is client
Unknown User•15mo ago
Message Not Public
Sign In & Join Server To View
It says in package.json it's 11.4.2 version
Unknown User•15mo ago
Message Not Public
Sign In & Join Server To View
Oh so thats the problem, got it