Skip to content

Tag: discord

Remove 1 element from Embed object DiscordJS

I have been trying to code a bot that copies 1 embed from 1 channel to another channel. But what I want it to do before posting it to the other channel, I want it to remove 1 element from the embed object. How I have it currently: As you can see i straight use message.embeds[0]. So i don’t even

How do I fix CLIENT_MISSING_INTENTS error?

I started learning about discord.js, but now I am facing this issue. I tried some googling, but I couldn’t manage to fix it. This is the error I am getting: Answer You need to specify the events which you want your bot to receive using gateway intents. Instead of const client = new Discord.Client(); Use…

discord.js Editing a message and sleeping

So I am very new to discord.js and wanted to know how I can edit a message and then sleep and then edit the message again so it doesn’t cause extremely fast edits. I found this code and couldn’t figure out what to do Answer As suggested by LercDsgn in the comments, you can use setTimeout to edit t…

Bot isn’t listening to guildMemberAdd

I signed up just a few moments ago because something was really bothering me: I have the following code: For some reason, when I leave and rejoin the server, the embed isn’t sending at all to the channel. I am getting no errors in the console. Any ideas on what may have gone wrong? Thanks. 🙂 Answer You …