It always says undefined, can you help me?

No description
7 Replies
d.js toolkit
d.js toolkit9mo 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!
Joãozinho
Joãozinho9mo ago
the membercount
duck
duck9mo ago
sounds each guildObject is an OAuth2Guild rather than a Guild object since you have the Guilds intent, your bot's guilds will be cached on ready, so there's no need to fetch guilds you'd just need to do this on ready rather than immediately after calling <Client>.login() without waiting for it to resolve
Joãozinho
Joãozinho9mo ago
How can I pull how many people are on that server?
Joãozinho
Joãozinho9mo ago
No description
Joãozinho
Joãozinho9mo ago
@duck
duck
duck9mo ago
by doing this on ready, then just getting the guilds from the cache rather than fetching then you can access <Guild>.memberCount