Replies: 1 comment 2 replies
-
Hi! Could you please provide an example reproducing the issue? You can fork the example here: https://github.com/socketio/socket.io-fiddle Without that, I'm afraid we won't be able to track down the issue. Thanks! |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I find I can trigger an unexpected socket.io connection under some circumstance
This is my client code (4.5.2)
But from console I only see my log "debug 2nd connection" once. I can't figure out where does the 2nd connection come from!
But I find under that circumstance if I set the function which will be called to a "real" function I can make the unexpected connection disappear: e.g. I change the code from
let aCB
tolet aCB = ()=>{}
to fix it.The
aCB
is a callback function my user may provide. If they don't provide it and I don't set it to noop or check it explicitly before calling it, the unexpected ws connection will show up.But why ? Any idea ?
Beta Was this translation helpful? Give feedback.
All reactions