Fold the servers' answers to one publish into an outcome. A server that answered more than once counts once, and an acceptance wins over a refusal, because the event is on that server either way.
The answers RelayPool.publish resolved with.
RelayPool.publish
Who accepted, who refused and why, and whether anyone accepted.
const outcome = summarizePublish(await pool.publish(relays, event));outcome.ok; // true when 2 of 3 accepted Copy
const outcome = summarizePublish(await pool.publish(relays, event));outcome.ok; // true when 2 of 3 accepted
Fold the servers' answers to one publish into an outcome. A server that answered more than once counts once, and an acceptance wins over a refusal, because the event is on that server either way.