From 8d3dbd24d975b90448998849b825808219bea9c8 Mon Sep 17 00:00:00 2001 From: rhearmas <34490428+qu-ota@users.noreply.github.com> Date: Sun, 22 Dec 2019 23:02:46 -0500 Subject: [PATCH] SPACES IN TEXT WERE DELETED --- commands/Fun/talk.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/commands/Fun/talk.js b/commands/Fun/talk.js index 6dce9d1..db000d1 100644 --- a/commands/Fun/talk.js +++ b/commands/Fun/talk.js @@ -14,8 +14,7 @@ exports.run = async (client, message, args) => { if(args[0].startsWith('<#') && args[0].endsWith('>')) { location = args[0].slice(2, -1); location = guild.channels.find(c => c.id === location); - msg = msg.replace(/[0-9]+/g, ""); - msg = msg.replace(/[$<#> ]+/g, ""); + msg = msg.replace(/[0-9]+/g, "").replace(/[$<#>]+/g, "").slice(1); console.log(`msg is ${msg}`) }