Stops path-proxy from crashing on error messages

This commit is contained in:
Simon Howe
2016-03-03 14:14:20 +01:00
parent 186a45e052
commit 28a9826689

View File

@@ -107,6 +107,7 @@ var proxyRules = new HttpProxyRules({
});
var pathProxy = httpProxy.createProxy({ws: true});
pathProxy.on('error', function(err) { console.error('path proxy error', err); });
var pathProxyPort = port + 1;
const proxyPathServer = http.createServer(function(req, res) {
var target = proxyRules.match(req);