Fix an issue where the word ACTION in a /me can be stripped

This commit is contained in:
David White 2014-10-02 15:25:31 +01:00
parent 18b41b8516
commit 58709d021d

View File

@ -32,7 +32,7 @@ module.exports = function(irc, network) {
var text = data.message; var text = data.message;
if (text.split(" ")[0] === "\u0001ACTION") { if (text.split(" ")[0] === "\u0001ACTION") {
type = Msg.Type.ACTION; type = Msg.Type.ACTION;
text = text.replace(/\u0001|ACTION/g, ""); text = text.replace(/^\u0001ACTION|\u0001$/g, "");
} }
text.split(" ").forEach(function(w) { text.split(" ").forEach(function(w) {