Browse Source

http: remove unneeded cb check from setTimeout()

- This check is already covered in EventEmitter#addListener()

Refs: https://github.com/nodejs/node/pull/3618
PR-URL: https://github.com/nodejs/node/pull/3631
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
process-exit-stdio-flushing
Ashok Suthar 9 years ago
committed by Jeremiah Senkpiel
parent
commit
8625a3815e
  1. 2
      lib/_http_outgoing.js

2
lib/_http_outgoing.js

@ -91,8 +91,6 @@ exports.OutgoingMessage = OutgoingMessage;
OutgoingMessage.prototype.setTimeout = function(msecs, callback) {
if (callback) {
if (typeof callback !== 'function')
throw new TypeError('callback must be a function');
this.on('timeout', callback);
}

Loading…
Cancel
Save