Skip to content

Commit 962958a

Browse files
Fix connection URL when resolving the scheme
In case the `connectionUrl` already starts with `//` the `//` in the concatination is redundant. This might be related to #87.
1 parent 64c858f commit 962958a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Observer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export default class {
66

77
if (connectionUrl.startsWith('//')) {
88
const scheme = window.location.protocol === 'https:' ? 'wss' : 'ws'
9-
connectionUrl = `${scheme}://${connectionUrl}`
9+
connectionUrl = `${scheme}:${connectionUrl}`
1010
}
1111

1212
this.connectionUrl = connectionUrl

0 commit comments

Comments
 (0)