Browse Source

http: Fix overlooked agent.globalAgent export

Noticed by @bnoordhuis in https://github.com/joyent/node/pull/5991#discussion_r5575946
v0.11.5-release
isaacs 12 years ago
parent
commit
32fdae2ca3
  1. 2
      lib/_http_agent.js
  2. 3
      lib/http.js

2
lib/_http_agent.js

@ -284,3 +284,5 @@ Agent.prototype.get = function(options, cb) {
req.end(); req.end();
return req; return req;
}; };
exports.globalAgent = new Agent();

3
lib/http.js

@ -42,8 +42,7 @@ exports.STATUS_CODES = server.STATUS_CODES;
var agent = require('_http_agent'); var agent = require('_http_agent');
var Agent = exports.Agent = agent.Agent; var Agent = exports.Agent = agent.Agent;
var globalAgent = new Agent(); var globalAgent = exports.globalAgent = agent.globalAgent;
exports.globalAgent = globalAgent;
var client = require('_http_client'); var client = require('_http_client');
var ClientRequest = exports.ClientRequest = client.ClientRequest; var ClientRequest = exports.ClientRequest = client.ClientRequest;

Loading…
Cancel
Save