Skip to content

Commit 4351ed1

Browse files
committed
[fix] closes #547
1 parent 0ba4fa8 commit 4351ed1

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

lib/http-proxy.js

+7
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,13 @@ var http = require('http'),
88
*/
99
module.exports = httpProxy.Server;
1010

11+
module.exports.createProxy = function(options) {
12+
return {
13+
web: httpProxy.createRightProxy('web')(options),
14+
ws: httpProxy.createRightProxy('ws')(options)
15+
};
16+
}
17+
1118
/**
1219
* Creates the proxy server.
1320
*

lib/http-proxy/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ function createRightProxy(type) {
8080
};
8181
};
8282
}
83-
83+
httpProxy.createRightProxy = createRightProxy;
8484

8585
function ProxyServer(options) {
8686
EE3.call(this);

0 commit comments

Comments
 (0)