From 84946b1fef64ee619f1c161d57ef4afdc533eae2 Mon Sep 17 00:00:00 2001 From: Christophe Besson Date: Sat, 17 Oct 2026 19:08:52 +0200 Subject: fix(spa): search hears a refused local network from the connection On a Pixel, Chrome still lists the refused address when search gives up, so nothing tells it from a silent node. The connection given up on now runs to its own verdict and the refusal is reported then. Co-Authored-By: Claude Opus 5.5 --- packages/meshbay-hub/src/meshbay_hub/static/transport.js | 16 ---------------- 1 file changed, 16 deletions(-) (limited to 'packages/meshbay-hub/src/meshbay_hub/static/transport.js') diff --git a/packages/meshbay-hub/src/meshbay_hub/static/transport.js b/packages/meshbay-hub/src/meshbay_hub/static/transport.js index 98a6ecfa..11088adc 100644 --- a/packages/meshbay-hub/src/meshbay_hub/static/transport.js +++ b/packages/meshbay-hub/src/meshbay_hub/static/transport.js @@ -844,21 +844,6 @@ class MeshBayTransport { this._wakeReconnect(); } - /** - * Whether the connection being made is refused the local network, read from - * what is paired so far: the signature is there as soon as ICE checks - * begin, where connect() names it only once ICE gives up, half a minute. - * For a caller that stops waiting before that (connection-pool.js). - */ - async localNetworkRefused() { - const pc = this._pc; - if (!pc || !this._rawAnswerSdp || !pc.localDescription) return false; - if (pc.iceConnectionState === 'connected' || pc.iceConnectionState === 'completed') { - return false; - } - return _localNetworkRefusedBy(pc, pc.localDescription.sdp, this._rawAnswerSdp); - } - get connected() { return this._connected; } /** True while _reconnectLoop is running, backoff included. */ get reconnecting() { return !!this._reconnectPromise; } @@ -1030,7 +1015,6 @@ class MeshBayTransport { // the composer, exactly like one that had. this._setDevicePk('', 'new connection'); this._sessionUp = false; - this._rawAnswerSdp = null; this._pc = new RTCPeerConnection({ iceServers: await iceServers() }); this._channel = this._pc.createDataChannel('mnp', { ordered: true }); -- cgit v1.2.3