Commit af0a82b6 authored by 神楽坂玲奈's avatar 神楽坂玲奈

fix

parent bf018d46
Pipeline #16082 passed with stages
in 34 seconds
......@@ -39,6 +39,7 @@ export class Router {
}
onMessage(socket: Socket, data: Report) {
console.log(`recv: ${this.id} ${JSON.stringify(data)} this.seq:${this.seq}`);
if (data.ack == this.seq + 1) {
this.time = Date.now();
if (data.peers) this.peers = data.peers;
......@@ -110,7 +111,7 @@ export class Router {
send(socket: Socket, via: Record<number, number>, plan: Record<number, number>) {
const message: Change = { seq: this.seq, via };
console.log(this.id, message);
console.log(`send: ${this.id} ${JSON.stringify(message)}`);
return socket.send(JSON.stringify(message), this.rinfo!.port, this.rinfo!.address);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment