Skip to content

Commit

Permalink
Truncate bookmark embed titles
Browse files Browse the repository at this point in the history
  • Loading branch information
Brainicism committed Nov 6, 2023
1 parent 3d478ef commit e033e48
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions src/helpers/discord_utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1611,13 +1611,16 @@ export async function sendBookmarkedSongs(
inline: boolean;
}> = [...songs].map((bookmarkedSong) => ({
name: `${bold(
`"${getLocalizedSongName(
bookmarkedSong[1].song,
locale,
)}" - ${getLocalizedArtistName(
bookmarkedSong[1].song,
locale,
)}`,
truncatedString(
`"${getLocalizedSongName(
bookmarkedSong[1].song,
locale,
)}" - ${getLocalizedArtistName(
bookmarkedSong[1].song,
locale,
)}`,
256,
),
)} (${standardDateFormat(bookmarkedSong[1].song.publishDate)})`,
value: `[${friendlyFormattedNumber(
bookmarkedSong[1].song.views,
Expand Down

0 comments on commit e033e48

Please sign in to comment.