You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This isn't happening for me in practice — trying to send before receiving a connect message gives me an error that the RTCDataChannel.readyState is not 'open'.
I'm guessing the correct fix here is to just delete that sentence from the README (happy to open a PR), but curious if there's something I'm doing wrong or misunderstanding, or if you have other thoughts.
The text was updated successfully, but these errors were encountered:
The README claims that if you try to send data before a connection has been established, the
send
method will buffer that message until it's ready: https://github.com/feross/simple-peer/blob/master/README.md#peersenddataThis isn't happening for me in practice — trying to send before receiving a
connect
message gives me an error that theRTCDataChannel.readyState
is not'open'
.Looking at the code,
peer.send
appears to just delegate straight to the underlying WebRTC method: https://github.com/feross/simple-peer/blob/master/index.js#L243-L245I'm guessing the correct fix here is to just delete that sentence from the README (happy to open a PR), but curious if there's something I'm doing wrong or misunderstanding, or if you have other thoughts.
The text was updated successfully, but these errors were encountered: