diff --git a/lib/node-http-proxy.js b/lib/node-http-proxy.js index ad59c2e62..f2054ac7b 100644 --- a/lib/node-http-proxy.js +++ b/lib/node-http-proxy.js @@ -25,7 +25,6 @@ */ var sys = require('sys'), - eyes = require('eyes'), http = require('http'), events = require('events'); @@ -74,7 +73,7 @@ exports.HttpProxy.prototype = { callback(req, res, self); } else { - self.proxyRequest(server, port, req, res); + self.proxyRequest(port, server, req, res); } }); @@ -114,7 +113,7 @@ exports.HttpProxy.prototype = { delete this.events[req]; }, - proxyRequest: function (server, port, req, res) { + proxyRequest: function (port, server, req, res) { // Remark: nodeProxy.body exists solely for testability this.body = ''; var self = this; diff --git a/test/node-http-proxy-test.js b/test/node-http-proxy-test.js index dc7037ecb..13cedf979 100644 --- a/test/node-http-proxy-test.js +++ b/test/node-http-proxy-test.js @@ -46,7 +46,7 @@ var startProxyServer = function (port, server, proxy) { // // Creates the reverse proxy server with a specified latency // -var startLatentProxyServer = function (server, port, proxy, latency) { +var startLatentProxyServer = function (port, server, proxy, latency) { // Initialize the nodeProxy and start proxying the request var proxyServer = proxy.createServer(function (req, res, proxy) { setTimeout(function () {