DIA
discord.js - Imagine an appGHIATH Alkhazraji
hi guys How can I show when the user entered the server in the embed?
hi guys How can I show when the user entered the server in the embed?
DT
d.js toolkit•91d 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!
- ✅
Marked as resolved by staffC
chewie 🌈•91d ago
use the guildMemberAdd event, you need the Guilds and GuildMembers intents for that
GA
GHIATH Alkhazraji•91d ago
{ name: 'joined at' , value:
${member.guildMemberAdd.toDateString()}
},
Cannot read properties of undefined (reading 'toDateString')@chewie 🌈
full codeC
chewie 🌈•91d ago
oh you mean it like that
sorry, use member.joinedAt
But you defined member as a user
so use getMember instead of getUser and use
member.user.createdAt
for the date when the account was createdGA
GHIATH Alkhazraji•91d ago
Cannot read properties of undefined (reading 'joinedAt')
@chewie 🌈
C
chewie 🌈•91d ago
thats not even close to what I told you to do
please read again
and you dont need to ping me every time
GA
GHIATH Alkhazraji•91d ago
im sorry
thats okay
Cannot read properties of undefined (reading 'joinedAt')
C
chewie 🌈•91d ago
no, its still member.joinedAt
GA
GHIATH Alkhazraji•91d ago
Cannot read properties of undefined (reading 'createdAt')
can you edit on it
I didn't understand you
C
chewie 🌈•91d ago
man
I didn't tell you to change the createdAt field
that was already fine
GA
GHIATH Alkhazraji•91d ago
ok
C
chewie 🌈•91d ago
member.user.createdAt
member.joinedAt
GA
GHIATH Alkhazraji•91d ago
1s
GA
GHIATH Alkhazraji•91d ago
GA
GHIATH Alkhazraji•91d ago
join at undefined
C
chewie 🌈•91d ago
did you provide a member in the command option
or did you leave it empty
let member = interaction.options.getMember('username');
if (!member) {
member = interaction.user;
}
that should be interaction.member, not user
GA
GHIATH Alkhazraji•91d ago
GA
GHIATH Alkhazraji•91d ago
same
I solved the problem
Thank you
M
Mutrax ¯\_(ツ)_/¯•91d ago
if problem is solved then pls press "mark post as solved". top of chat
Support server for discord.js, a Node.js module to interact with the Discord bot API.
58KMembers
View on DiscordWant results from more Discord servers?
More PostsCan someone explain me how I can use the sequelize?I coppied the repo from discord.js but how I can test the content? In my DBInteractions overlapping? (I don't know what even happening anymore)I have command that sends a ephemeral message with buttons, and then using message collector to get URL Audio Resource Streaming Stopped Workingidk whats going on so maybe one of you can help... my bot has been broken for a few months I thoughtHow to make an autocomplete list from mongodb entriesSo I have an array of objects, i want to display the name field of each object in a list, and then oSend message to specific channelHow can I send a message to a specific channel of my guild?Ticket SupportWhy when i run the bot, the terminal gave me this error?Can someone help to complete this command?I have a ticket command here, but I don't know how to make a channel that opens from a button:Webhook send channelId optionIs it possible to parse a channel ID on the webhook.send method for it to send to a thread rather thIssue with Select MenuHello, I'm new with select menus, I tried them today but the bot isn't responding to them. The consoinvalid from body```DiscordAPIError[50035]: Invalid Form Body
14.options[3][APPLICATION_COMMAND_OPTIONS_TYPE_INVALID]invalid from body```DiscordAPIError[50035]: Invalid Form Body
14.options[3][APPLICATION_COMMAND_OPTIONS_TYPE_INVALID]LatencyAfter I created shards for bot, latency went from 8-10 to 200 and this happens sometimesmodal submit unknown interaction```js
await interaction.showModal(modal); //ButtonInteraction
const filter = (i) =>
MODALhey, how can add textlabel in modal please?Add points to multiple users at onceI want to make 3 optional options to add points to multiple users at once, How can I achieve that wiAuthentication failed at WebSocketShard.onCloseI get this error once every few weeks and discord resets my bot's token.
```Unhandled rejection: AutFor some reason my collecter won't work?It doesn't give me an error or anything and ive been debugging for about 6 hours now. Any pointers aEmbed is only sending once every time the slash command is ran every active sessionBy every active session I mean every time the bot is online.
I have a slash command that is like anDownload Node JS without admin rightsHello i want to know if it's possible to install node js npm without admin rights please403 Error due to new image expiration?Hey all, I'm unfortunately having issues with a ticket transcript system that I created for my disco