Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/http-proxy/common.js
@@ -75,7 +75,7 @@ common.setupSocket = function(socket) {
};

common.getPort = function(req) {
var res = req.headers.host.match(/:(\d+)/);
var res = req.headers.host ? req.headers.host.match(/:(\d+)/) : "";
return res ?
res[1] :
req.connection.pair ? '443' : '80' ;