From 12c7721ef5f012de1bb87b188b83fe01a42e403f Mon Sep 17 00:00:00 2001 From: Alexander Mills Date: Mon, 5 Aug 2013 16:53:29 +0100 Subject: [PATCH] fixed bug with ACTION, replaced with users name --- modules/regex/regex.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modules/regex/regex.js b/modules/regex/regex.js index 48b8e21..a3a6c6f 100644 --- a/modules/regex/regex.js +++ b/modules/regex/regex.js @@ -17,10 +17,12 @@ var regex = function(dbot) { var user = q[1]; last = this.last[event.channel.name][user]; replacement = last.replace(toMatch, replaceWith); + replacement = replacement.replace("\x01", '').replace(/^.ACTION/, user); if(replacement != last) event.reply(event.user + " thinks " + user + " meant: " + replacement); } else { last = this.last[event.channel.name][event.user]; replacement = last.replace(toMatch, replaceWith); + replacement = replacement.replace("\x01", '').replace(/^.ACTION/, event.user); if(replacement != last) event.reply(event.user + " meant: " + replacement); } } else {