TypeError: Cannot read property 'users' of undefined
I was trying to make a const member but it says "TypeError: Cannot read property 'users' of undefined"
module.exports = {
name: 'welcome',
description: 'welcome',
execute(message, args, Discord) {
const member = message.mentions.users.first();
if(message.member.permissions.has('ADMINISTRATOR')){
message.channel.send(
new MessageEmbed()
.setTitle('title')
.setImage('imageurl')
.setDescription('desc')
)
}else{
return message.channel.send(`You don't have any permissions to do that!`)
}
}
}
from Recent Questions - Stack Overflow https://ift.tt/3avALjB
https://ift.tt/eA8V8J
Comments
Post a Comment