superagent
Advanced tools
Comparing version 0.8.1 to 0.8.2
0.8.2 / 2012-08-28 | ||
================== | ||
* fix pathname relative redirects. Closes #112 | ||
0.8.1 / 2012-08-21 | ||
@@ -3,0 +8,0 @@ ================== |
@@ -406,3 +406,10 @@ | ||
var url = res.headers.location; | ||
if (!~url.indexOf('://')) url = this.protocol + url; | ||
if (!~url.indexOf('://')) { | ||
if (0 != url.indexOf('//')) { | ||
url = '//' + this.host + url; | ||
} | ||
url = this.protocol + url; | ||
} | ||
delete this.req; | ||
@@ -480,2 +487,3 @@ this.method = 'HEAD' == this.method | ||
this.protocol = url.protocol; | ||
this.host = url.host; | ||
@@ -482,0 +490,0 @@ // expose events |
{ | ||
"name": "superagent" | ||
, "version": "0.8.1" | ||
, "version": "0.8.2" | ||
, "description": "elegant & feature rich browser / node HTTP with a fluent API" | ||
@@ -5,0 +5,0 @@ , "keywords": ["http", "ajax", "request", "agent"] |
90078
2675