Closed haydenyoung closed 1 year ago
How about:
const stringPeers = peers.map(e => String(e)); const hasAllPeers = peersToWait.map(e => String(e)).map((e) => stringPeers.includes(e)).filter((e) => e === false).length === 0
Thanks @julienmalard. I used idPeers and idPeersToWait as I felt id better reflected the info in those arrays. Happy to change, though, if you feel "string" is more acceptable.
This PR now addresses the db sync on peer connect issue as well.
I like your variable names better too @haydenyoung ! Anyways we'll see what the maintainers think.
hi @alanshaw how are you? :) Might you be able to merge this or point us in the direction of somebody who could?
@haadcode @alanshaw Would it be possible to publish a release on NPM so that this could be update as an orbit-db dependency as well?
Checking for peers who are subscribed to direct connection messages is failing because peers cannot be filtered by object. Instead, convert the peer to its address and then check it against the subscription list.