Skip to content

Commit b0e3cc4

Browse files
committed
Merge pull request joewalnes#34 from uecasm/patch-2
Fix TypeError when no options provided
2 parents 5a883c4 + 29255d3 commit b0e3cc4

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

reconnecting-websocket.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,7 @@
109109
/** The maximum time in milliseconds to wait for a connection to succeed before closing and retrying. */
110110
timeoutInterval: 2000
111111
}
112+
if (!options) { options = {}; }
112113

113114
// Overwrite and define settings with options if they exist.
114115
for (var key in settings) {

0 commit comments

Comments
 (0)