We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9d01506 commit 11a4358Copy full SHA for 11a4358
src/lib/Tree.ts
@@ -52,13 +52,13 @@ export class Bookmark<L extends TItemLocation> {
52
throw new Error('Location failed validation')
53
}
54
55
- // not a regular bookmark
56
- if (STRANGE_PROTOCOLS.some(proto => url.indexOf(proto) === 0)) {
57
- this.url = url
58
- return
59
- }
60
-
61
try {
+ // not a regular bookmark
+ if (STRANGE_PROTOCOLS.some(proto => url.indexOf(proto) === 0)) {
+ this.url = url
+ return
+ }
+
62
const urlObj = new URL(url)
63
this.url = urlObj.href
64
} catch (e) {
0 commit comments