Skip to content

Commit 395e324

Browse files
committed
http: remove unneeded cb check from setTimeout
- check is already covered by event emitter
1 parent a3b238a commit 395e324

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

lib/_http_outgoing.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,6 @@ exports.OutgoingMessage = OutgoingMessage;
9191
OutgoingMessage.prototype.setTimeout = function(msecs, callback) {
9292

9393
if (callback) {
94-
if (typeof callback !== 'function')
95-
throw new TypeError('callback must be a function');
9694
this.on('timeout', callback);
9795
}
9896

0 commit comments

Comments
 (0)