mafintosh / webrtc-swarm

Create a swarm of p2p connections using webrtc and a signalhub
MIT License
380 stars 60 forks source link

`unwrap()` broken #27

Closed perguth closed 6 years ago

perguth commented 6 years ago

In https://github.com/mafintosh/webrtc-swarm/commit/ce77175c7d48cf4fad11c5e40f8869ebf0d7f303#diff-168726dbe96b3ce427e7fedce31bb0bcR143 an error got introduced regarding the usage of the unwrap function:

Until that commit the unwrap function was called with the channels ID as the second argument. That's either /all or swarm.me (ID of the receiving node). After the aforementioned commit unwrap was called with /all in all cases.

The commit message does not mention any reason regarding that change:

  • Refactor + added close method and test
  • privatized setup and randomized test key

So I am quite certain this behaviour was introduced by accident.