Fix url.format usage of path on node@0.11.15
node@0.11.15 was released with a patch that adds support for `path` to url.format (d312b6d15c
). However, this broke `npm install` for git+ssh urls and as such has been reverted on io.js, making it work like on node@0.11.14 again.913addbff5
This commit is contained in:
parent
abd5e79223
commit
d108926f46
1 changed files with 4 additions and 0 deletions
|
@ -117,6 +117,8 @@ module.exports = {
|
||||||
set path(path) {
|
set path(path) {
|
||||||
var url = parse(this.req);
|
var url = parse(this.req);
|
||||||
url.pathname = path;
|
url.pathname = path;
|
||||||
|
url.path = null;
|
||||||
|
|
||||||
this.url = stringify(url);
|
this.url = stringify(url);
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -167,6 +169,8 @@ module.exports = {
|
||||||
set querystring(str) {
|
set querystring(str) {
|
||||||
var url = parse(this.req);
|
var url = parse(this.req);
|
||||||
url.search = str;
|
url.search = str;
|
||||||
|
url.path = null;
|
||||||
|
|
||||||
this.url = stringify(url);
|
this.url = stringify(url);
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue