Error fetching channel

*sry wrong title, should be setNicknames doesnt always update
let getguild = await client.guilds.cache.get("ID")
let userToAddRole = await getguild.members.fetch("ID")
userToAddRole.setNickname(`[WN] ${userToAddRole.user.username}`)
let getguild = await client.guilds.cache.get("ID")
let userToAddRole = await getguild.members.fetch("ID")
userToAddRole.setNickname(`[WN] ${userToAddRole.user.username}`)
this sometimes updates the nicknames, but sometimes doesnt. Any reasons why this would be the case?
4 Replies
d.js docs
d.js docs3y ago
• 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.
monbrey
monbrey3y ago
Rate limiting is the only reason I can think of
Mulo
MuloOP3y ago
what that'd be? once a sec?
monbrey
monbrey3y ago
No idea
Want results from more Discord servers?
Add your server