Commit 465554aa authored by Hugo "ThePooN" Denizart's avatar Hugo "ThePooN" Denizart
Browse files

Support ACTION messages with no space

More or less IRC compliant, like all IRC things.
See https://tools.ietf.org/id/draft-oakley-irc-ctcp-01.html#rfc.appendix.A.1
parent ab3f14fb
Pipeline #4156 passed with stage
in 56 seconds
// eslint-disable-next-line no-control-regex
const actionRegex = /^\x01ACTION (.+)\x01$/;
const actionRegex = /^\x01ACTION( (.+)?)?\x01$/;
/**
* Bancho incoming message
......@@ -40,7 +40,7 @@ class BanchoMessage {
getAction() {
const action = actionRegex.exec(this.message);
if(action)
return action[1];
return action[2] || "";
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment