Skip to content

Commit

Permalink
Implement RoutingProxy.prototype.remove
Browse files Browse the repository at this point in the history
  • Loading branch information
tellnes committed May 17, 2012
1 parent f223ce8 commit 0532995
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lib/node-http-proxy/routing-proxy.js
Expand Up @@ -120,7 +120,11 @@ RoutingProxy.prototype.add = function (options) {
// for the specified `options.host` and `options.port` (if they exist).
//
RoutingProxy.prototype.remove = function (options) {
var key = this._getKey(options);
var key = this._getKey(options),
proxy = this.proxies[key];

delete this.proxies[key];
return proxy;
};

//
Expand Down

0 comments on commit 0532995

Please sign in to comment.