Skip to content

Commit

Permalink
Bold clip title without breaking link preview
Browse files Browse the repository at this point in the history
  • Loading branch information
jaredcat committed Apr 10, 2024
1 parent 0e3a1d1 commit 4c4af73
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,7 @@ async function main(): Promise<void> {
method: options.method,
url: options.url,
data: {
content: `[${clipInfo.title}](${clipInfo.url})`,
content: `[**${clipInfo.title}**](${clipInfo.url})`,
},
};
logger.log('debug', 'POST: 1 of 2 requests with options', initialMessage);
Expand Down Expand Up @@ -410,7 +410,7 @@ async function main(): Promise<void> {
let playingStr = '';
// underscores, and asterisks on the next two lines are Discord markdown formatting
if (gameInfo) playingStr = ` playing __${gameInfo.name}__`;
const string = `[${clipInfo.title}](${clipInfo.url})\n\n*${userInfo.display_name}* created a clip of *${broadcasterInfo.display_name}*${playingStr}`;
const string = `[**${clipInfo.title}**](${clipInfo.url})\n\n*${userInfo.display_name}* created a clip of *${broadcasterInfo.display_name}*${playingStr}`;
return { content: string };
}

Expand Down

0 comments on commit 4c4af73

Please sign in to comment.