Extracts a CTCP command and its arguments from a message body.
CTCP wraps the payload in \x01 delimiters, e.g. an action is \x01ACTION waves\x01. Returns
the uppercased command and the remaining argument string, or undefined when the text is not
CTCP-wrapped.
Parameters
text: string
The PRIVMSG/NOTICE body.
Returns {args:string;command:string}|undefined
{ command, args } for a CTCP payload, else undefined.
Extracts a CTCP command and its arguments from a message body.
CTCP wraps the payload in
\x01delimiters, e.g. an action is\x01ACTION waves\x01. Returns the uppercased command and the remaining argument string, orundefinedwhen the text is not CTCP-wrapped.