From 14f61d88ffb5ac7f66d46e0155833d32d46802d6 Mon Sep 17 00:00:00 2001 From: Zachery Notz Date: Sat, 23 May 2020 17:14:31 -0700 Subject: Improved regex so that TELLRAW templates can use variables more than once --- src/Discord.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Discord.ts b/src/Discord.ts index 2893c8b..c9b3b74 100644 --- a/src/Discord.ts +++ b/src/Discord.ts @@ -140,9 +140,9 @@ class Discord { } return this.config.MINECRAFT_TELLRAW_TEMPLATE - .replace('%username%', variables.username) - .replace('%discriminator%', variables.discriminator) - .replace('%message%', variables.text) + .replace(/%username%/g, variables.username) + .replace(/%discriminator%/g, variables.discriminator) + .replace(/%message%/g, variables.text) } private replaceDiscordMentions(message: string): string { -- cgit 1.4.1 /table>
summary refs log tree commit diff
path: root/bin/1sh/TOUR (unfollow)
Commit message (Expand)Author
2020-05-22Add The Hundred Thousand KingdomsJune McEnroe
2020-05-20Add RFC man-like to planJune McEnroe
2020-05-14Add hi rule for sh arithmetic expansionJune McEnroe
2020-05-13Remove gpg symlink from NetBSD installJune McEnroe
2020-05-11Add AutonomousJune McEnroe
2020-05-08Move keyboard layout into a .bundleJune McEnroe
2020-05-07Remove mkshJune McEnroe
2020-05-07Emulate 1sh prompts in bashJune McEnroe
2020-05-07Update nvim MANPAGERJune McEnroe
2020-05-06Post "casual update"June McEnroe
2020-05-06Remove bman functionJune McEnroe