Skip to content

Commit

Permalink
fix: actually replace all the double braces
Browse files Browse the repository at this point in the history
  • Loading branch information
BenSegal855 committed Dec 29, 2020
1 parent e148160 commit 30b63a3
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/commands/Fun/xkcd.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,12 +54,12 @@ export default class extends SteveCommand {
*/
private createComicEmbed(comic: XkcdComic): MessageEmbed {
const description = (comic.transcript || comic.alt)
.replace('{{', '{')
.replace('}}', '}')
.replace('[[', '[')
.replace(']]', ']')
.replace('<<', '<')
.replace('>>', '>');
.replace(/{{/g, '{')
.replace(/}}/g, '}')
.replace(/\[\[/g, '[')
.replace(/]]/g, ']')
.replace(/<</g, '<')
.replace(/>>/g, '>');
return new MessageEmbed()
.setColor(0x2242c7)
.setDescription(`${description}\n\nhttps://xkcd.com/${comic.num}/`)
Expand Down

0 comments on commit 30b63a3

Please sign in to comment.