2
0
mirror of https://github.com/tenrok/axios.git synced 2026-05-27 14:47:43 +03:00

fix proxy bugs

This commit is contained in:
Jared Lotti
2016-10-17 15:18:18 -04:00
committed by GitHub
parent 3f8b128da4
commit 5c4ca4ccc4
+2
View File
@@ -94,6 +94,8 @@ module.exports = function httpAdapter(config) {
if (proxy) {
options.host = proxy.host;
options.hostname = proxy.host;
options.headers.host = parsed.hostname;
options.port = proxy.port;
options.path = parsed.protocol + '//' + parsed.hostname + (parsed.port ? ':' + parsed.port : '') + options.path;
}