diff --git a/lib/_http_agent.js b/lib/_http_agent.js index 6ea801c3ed2af6..2a07cd25e26dd9 100644 --- a/lib/_http_agent.js +++ b/lib/_http_agent.js @@ -91,7 +91,7 @@ Agent.defaultMaxSockets = Infinity; Agent.prototype.createConnection = net.createConnection; // Get the key for a given set of request options -Agent.prototype.getName = function(options) { +Agent.prototype.getName = function getName(options) { var name = options.host || 'localhost'; name += ':'; @@ -110,7 +110,7 @@ Agent.prototype.getName = function(options) { return name; }; -Agent.prototype.addRequest = function(req, options) { +Agent.prototype.addRequest = function addRequest(req, options) { // Legacy API: addRequest(req, host, port, localAddress) if (typeof options === 'string') { options = { @@ -173,7 +173,7 @@ Agent.prototype.addRequest = function(req, options) { } }; -Agent.prototype.createSocket = function(req, options, cb) { +Agent.prototype.createSocket = function createSocket(req, options, cb) { var self = this; options = util._extend({}, options); options = util._extend(options, self.options); @@ -236,7 +236,7 @@ Agent.prototype.createSocket = function(req, options, cb) { } }; -Agent.prototype.removeSocket = function(s, options) { +Agent.prototype.removeSocket = function removeSocket(s, options) { var name = this.getName(options); debug('removeSocket', name, 'writable:', s.writable); var sets = [this.sockets]; @@ -275,7 +275,7 @@ Agent.prototype.removeSocket = function(s, options) { } }; -Agent.prototype.destroy = function() { +Agent.prototype.destroy = function destroy() { var sets = [this.freeSockets, this.sockets]; for (var s = 0; s < sets.length; s++) { var set = sets[s];