-
Notifications
You must be signed in to change notification settings - Fork 421
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Handle errors when parsing message #64
Comments
Hmmm, failing that far down in the message parsing strikes me as very odd. Are you able to give me some connection details to the specific IRC server that's causing those issues (and I'll take a closer look). Thanks, |
I'm using https://grove.io/ I've been unable to debug it properly because the code is deployed on heroku, but I think I've managed to replicate the error on a consistent basis. Tonight I'll set it up at home, with some Cheers |
It looks like the problem occurs with the |
I ran it at home and the problem is here: match = line.match(/^([^ ]+) +/);
message.command = match[1]; At this point, line is exactly 'QUIT', with no trailing whitespace, so there's no match and the next line fails because |
Hey! I just wanted to let you know that I've added an extra space after the QUIT command. Actually, I've added a space after any command that contains no params or message. I think that should help with the parsing. |
👍 |
Update eslint to the latest version
I'm getting this error sporadically with irc 0.3.2:
And the problem is that
match
can be null under some circumstances (which I haven't pinned down yet).Maybe wrapping https://github.com/martynsmith/node-irc/blob/master/lib/irc.js#L506-513 with an
if ( line.trim() != '' )
could fix it?The text was updated successfully, but these errors were encountered: