Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[minor] Name functions
  • Loading branch information
mmalecki committed Sep 25, 2012
1 parent e477cb8 commit b3ae0f2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/http-proxy/http-proxy.js
Expand Up @@ -232,7 +232,7 @@ HttpProxy.prototype.proxyRequest = function (req, res, buffer) {
// Open new HTTP request to internal resource with will act
// as a reverse proxy pass
//
reverseProxy = this.target.protocol.request(outgoing, function (response) {
reverseProxy = this.target.protocol.request(outgoing, function onResponse(response) {
//
// Process the `reverseProxy` `response` when it's received.
//
Expand Down Expand Up @@ -273,7 +273,7 @@ HttpProxy.prototype.proxyRequest = function (req, res, buffer) {
// already been called and the 'error' event listener
// removed.
//
response.on('end', function () {
response.on('end', function onEnd() {
if (!errState) {
reverseProxy.removeListener('error', proxyError);
}
Expand All @@ -291,7 +291,7 @@ HttpProxy.prototype.proxyRequest = function (req, res, buffer) {
//
// If `req` is aborted, we abort our `reverseProxy` request as well.
//
req.on('aborted', function () {
req.on('aborted', function onAborted() {
reverseProxy.abort();
});

Expand Down

0 comments on commit b3ae0f2

Please sign in to comment.