added the ability to set a host's host to false, causing the urls it creates to be relative
This commit is contained in:
@ -135,7 +135,11 @@ Host.prototype.makeUrl = function (params) {
|
||||
auth = this.auth + '@';
|
||||
}
|
||||
|
||||
return this.protocol + '://' + auth + this.host + port + path + (query ? '?' + query : '');
|
||||
if (this.host) {
|
||||
return this.protocol + '://' + auth + this.host + port + path + (query ? '?' + query : '');
|
||||
} else {
|
||||
return path + (query ? '?' + query : '');
|
||||
}
|
||||
};
|
||||
|
||||
Host.prototype.toString = function () {
|
||||
|
||||
Reference in New Issue
Block a user