bare-url 2.0.4 → 2.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CMakeLists.txt
CHANGED
package/index.js
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
/* global Bare */
|
|
2
2
|
const path = require('bare-path')
|
|
3
|
-
const safetyCatch = require('safety-catch')
|
|
4
3
|
const binding = require('./binding')
|
|
5
4
|
const errors = require('./lib/errors')
|
|
6
5
|
|
|
@@ -214,7 +213,7 @@ const URL = module.exports = exports = class URL {
|
|
|
214
213
|
try {
|
|
215
214
|
this._href = binding.parse(String(href), base ? String(base) : null, this._components, shouldThrow)
|
|
216
215
|
} catch (err) {
|
|
217
|
-
|
|
216
|
+
if (err instanceof TypeError) throw err
|
|
218
217
|
|
|
219
218
|
throw errors.INVALID_URL()
|
|
220
219
|
}
|
|
@@ -224,7 +223,7 @@ const URL = module.exports = exports = class URL {
|
|
|
224
223
|
try {
|
|
225
224
|
this._parse(href, null, true)
|
|
226
225
|
} catch (err) {
|
|
227
|
-
|
|
226
|
+
if (err instanceof TypeError) throw err
|
|
228
227
|
}
|
|
229
228
|
}
|
|
230
229
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "bare-url",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.6",
|
|
4
4
|
"description": "WHATWG URL implementation for JavaScript",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"files": [
|
|
@@ -30,8 +30,7 @@
|
|
|
30
30
|
},
|
|
31
31
|
"homepage": "https://github.com/holepunchto/bare-url",
|
|
32
32
|
"dependencies": {
|
|
33
|
-
"bare-path": "^3.0.0"
|
|
34
|
-
"safety-catch": "^1.0.2"
|
|
33
|
+
"bare-path": "^3.0.0"
|
|
35
34
|
},
|
|
36
35
|
"devDependencies": {
|
|
37
36
|
"brittle": "^3.3.2",
|
|
Binary file
|
|
Binary file
|