avatar options
I want it to get the target avatar when the command user put it in but if there is no target then it would get the command user avatar. It works fine when there is a target but doesnt when there is no target. I believe the problem area is this part " interaction.user.avatarURL();
const exampleEmbed = new EmbedBuilder()
.setColor(0x0099FF).setImage(avatar).setTimestamp()
.setFooter({ text: interaction.options.getMember('target').user.username || interaction.member.username })
return interaction.reply({ embeds: [exampleEmbed] });
;
},
};
```
const exampleEmbed = new EmbedBuilder()
.setColor(0x0099FF).setImage(avatar).setTimestamp()
.setFooter({ text: interaction.options.getMember('target').user.username || interaction.member.username })
return interaction.reply({ embeds: [exampleEmbed] });
;
},
};
```
