Skip to content

Commit

Permalink
Remove discord tag from member achievements. (#252)
Browse files Browse the repository at this point in the history
  • Loading branch information
Aluminoti authored Jul 2, 2024
1 parent 63c4463 commit 38866bb
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/events/instances/MemberAchievements.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,13 @@ class MemberAchievements implements Event {
if (!groupId) return;

const userId = await getUserId(player.displayName);
const discordTag = userId ? `(<@${userId}>)` : '';

const message = new EmbedBuilder()
.setColor(config.visuals.blue)
.setTitle(`🎉 New member ${achievements.length > 1 ? 'achievements' : 'achievement'}`)
.setDescription(
achievements
.map(({ metric, name }) => `${player.displayName} ${discordTag} - ${getEmoji(metric)} ${name}`)
.map(({ metric, name }) => `${player.displayName} - ${getEmoji(metric)} ${name}`)
.join('\n')
)
.setURL(encodeURL(`https://wiseoldman.net/players/${player.displayName}/achievements`));
Expand Down

0 comments on commit 38866bb

Please sign in to comment.