Skip to content

Support + and ! channels #99

wants to merge 1 commit into from
+1 −1
2 lib/irc.js
@@ -382,7 +382,7 @@ function Client(server, nick, opt) {
self.emit('message', from, to, text, message);
- if ( to.match(/^[&#]/) ) {
+ if ( to.match(/^[&#+!]/) ) {
damianb added a note Aug 13, 2012

have you tested this to confirm it works? those are regex metachars...

tuhoojabotti added a note Aug 13, 2012

They do work in character sets, but of course escaping them might be good practice.

damianb added a note Aug 13, 2012

yeah, that's what's been ground into me by my mentors for years, heh. wasn't aware that it wasn't necessary in sets, but I think I'll keep the habit for clarity's sake.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
self.emit('message#', from, to, text, message);
self.emit('message' + to, from, text, message);
if ( to != to.toLowerCase() ) {
Something went wrong with that request. Please try again.