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?
19 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 staffuse the guildMemberAdd event, you need the Guilds and GuildMembers intents for that
{ name: 'joined at' , value:
${member.guildMemberAdd.toDateString()}
},
Cannot read properties of undefined (reading 'toDateString')@chewie 🌈
full codeoh 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 createdCannot read properties of undefined (reading 'joinedAt')
@chewie 🌈
thats not even close to what I told you to do
please read again
and you dont need to ping me every time
im sorry
thats okay
Cannot read properties of undefined (reading 'joinedAt')
no, its still member.joinedAt
Cannot read properties of undefined (reading 'createdAt')
can you edit on it
I didn't understand you
man
I didn't tell you to change the createdAt field
that was already fine
ok
member.user.createdAt
member.joinedAt
1s
join at undefined
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
same
I solved the problem
Thank you
if problem is solved then pls press "mark post as solved". top of chat