Skip to content


Subversion checkout URL

You can clone with
Download ZIP


Issuing NICK during session breaks JOIN #93

toolness opened this Issue · 1 comment

3 participants


When I issue a NICK command and later issue a JOIN command, the following exception is thrown:

                    throw err;
TypeError: Cannot read property 'users' of undefined
    at Client.<anonymous> (/Users/atul/Documents/explorations/irc-fun/node_modules/irc/lib/irc.js:325:28)
    at Client.emit (events.js:88:20)
    at /Users/atul/Documents/explorations/irc-fun/node_modules/irc/lib/irc.js:546:22
    at Array.forEach (native)
    at Socket.<anonymous> (/Users/atul/Documents/explorations/irc-fun/node_modules/irc/lib/irc.js:543:15)
    at Socket.emit (events.js:67:17)
    at TCP.onread (net.js:362:31)

It looks like that's right here. The exception is being thrown because self.nick wasn't updated when the NICK command was issued.

@toolness toolness referenced this issue from a commit in toolness/steampunk
@toolness toolness irc dependency now refers to my fork of node-irc.
This is because my fork fixes martynsmith/node-irc#93. I will update
it to the npm version once that bug is officially resolved.

Found this error too, the problem is indeed in that line

@martynsmith martynsmith closed this issue from a commit
@toolness toolness When a NICK command is received, update self.nick if needed.
This should fix #93, though I don't know if arbitrarily changing
self.nick in the middle of a session breaks other expectations about
the way the code works.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.