Browse Source

Return the EventEmitter from addListener for chaining.

http://groups.google.com/group/nodejs/browse_thread/thread/13708eacedb40b36
v0.7.4-release
Ryan 16 years ago
parent
commit
b590a45849
  1. 1
      src/events.js

1
src/events.js

@ -8,6 +8,7 @@ node.EventEmitter.prototype.addListener = function (type, listener) {
if (!this._events.hasOwnProperty(type)) this._events[type] = [];
this._events[type].push(listener);
}
return this;
};
node.EventEmitter.prototype.listeners = function (type) {

Loading…
Cancel
Save