mirror of
https://github.com/Yonle/bostr.git
synced 2025-09-24 07:11:46 +02:00
fix the improvement for pendingEOSE in mode 2
Signed-off-by: Yonle <yonle@lecturify.net>
This commit is contained in:
@@ -128,7 +128,7 @@ function newConn(addr, id) {
|
||||
case "EOSE":
|
||||
if (!pendingEOSE.has(id + ":" + data[1])) return;
|
||||
pendingEOSE.set(id + ":" + data[1], pendingEOSE.get(id + ":" + data[1]) + 1);
|
||||
if (pendingEOSE.get(id + ":" + data[1]) < relays.length) return;
|
||||
if (pendingEOSE.get(id + ":" + data[1]) < Object.from(relays).filter(_ => _.id === id).length) return;
|
||||
csess.get(id)?.send(JSON.stringify(data));
|
||||
break;
|
||||
}
|
||||
|
Reference in New Issue
Block a user