Merge pull request #109 from jnordberg/master

command line tool - make sure targetPort is an integer
This commit is contained in:
Charlie Robbins 2011-09-18 18:49:39 -07:00
commit 787370ee87

View File

@ -64,7 +64,7 @@ if (typeof target === 'string') location = target.split(':');
//
var server;
if (location) {
var targetPort = location.length === 1 ? 80 : location[1];
var targetPort = location.length === 1 ? 80 : parseInt(location[1]);
server = httpProxy.createServer(targetPort, location[0], config);
}
else if (config.router) {