Skip to content
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

add names#channel event #129

Merged
merged 1 commit into from
Jan 20, 2013
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions docs/API.rst
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,12 @@ Events
callback is keyed by nick names, and has values '', '+', or '@' depending on the
level of that nick in the channel.

.. js:data:: 'names#channel'

`function (nicks) { }`

As per 'names' event but only emits for the subscribed channel.

.. js:data:: 'topic'

`function (channel, topic, nick, message) { }`
Expand Down
1 change: 1 addition & 0 deletions lib/irc.js
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,7 @@ function Client(server, nick, opt) {
var channel = self.chanData(message.args[1]);
if ( channel ) {
self.emit('names', message.args[1], channel.users);
self.emit('names' + message.args[1], channel.users);
self.send('MODE', message.args[1]);
}
break;
Expand Down
5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"description" : "An IRC client library for node",
"version" : "0.3.5",
"author" : "Martyn Smith <[email protected]>",
"contributors" : [],
"contributors" : [ {
"name": "xAndy",
"email": "[email protected]"
} ],
"repository" : {
"type" : "git",
"url" : "http://github.com/martynsmith/node-irc"
Expand Down