Comparing version 0.1.1 to 0.1.2
@@ -30,7 +30,13 @@ 'use strict'; | ||
this._host = config.host; | ||
if (this._host && this._host.startsWith('http://')) { | ||
if (config.https !== true) { | ||
this._useHttps = false; | ||
if (this._host) { | ||
if (this._host.startsWith('http://')) { | ||
if (config.https !== true) { | ||
this._useHttps = false; | ||
} | ||
this._host = this._host.substr(7); | ||
} else if (this._host.startsWith('https://')) { | ||
this._host = this._host.substr(8); | ||
} else if (this._host.indexOf('://') > -1) { | ||
throw new Error('Unsupported host protocol'); | ||
} | ||
this._host = this._host.substr(0, 7); | ||
} | ||
@@ -37,0 +43,0 @@ this._httpController = config.hasOwnProperty('httpController') ? config.httpController : require('./HttpController.browser'); |
{ | ||
"name": "ibeam", | ||
"version": "0.1.1", | ||
"version": "0.1.2", | ||
"files": [ | ||
@@ -5,0 +5,0 @@ "http-browser.js", |
No README
QualityPackage does not have a README. This may indicate a failed publish or a low quality package.
Found 1 instance in 1 package
13882
12
333
1
2