Skip to content

feat: emit error on connections when receiving "EXPIRE" - #1125

Open
WofWca wants to merge 3 commits into
peers:masterfrom
WofWca:patch-1
Open

feat: emit error on connections when receiving "EXPIRE"#1125
WofWca wants to merge 3 commits into
peers:masterfrom
WofWca:patch-1

Conversation

@WofWca

@WofWca WofWca commented Aug 26, 2023

Copy link
Copy Markdown
Contributor

Closes #924

TODO:

### TODO:
- [x] Update docs as well ("Be sure to listen on the [error](https://peerjs.com/docs/#peeron-error) event in case the connection fails.")
- [x] Think whether it breaks something (I'm not that deep into how PeerJS works).
- [ ] Address https://github.com/peers/peerjs/issues/924#issuecomment-1694381633 as well, or make an issue about it.

Comment thread lib/peer.ts Outdated
@jonasgloning

jonasgloning commented Aug 26, 2023

Copy link
Copy Markdown
Member

Hey @WofWca, thanks for working on this!
I pushed some commits, I hope that's ok:

  1. Emit the error only if the target .peer of the connection matches
  2. Some basic tests

I don't think this will break something.

@WofWca

WofWca commented Aug 28, 2023

Copy link
Copy Markdown
Contributor Author

Alright, looks like it's your MR now XD

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Error expected on DataConnection when not establishing a connection

2 participants