INNER CODE UNIT · TypeScript
excess
voxelize/voxelize · packages/core/src/core/network/index.ts:388
const excess = this.packetQueue.length - this.options.maxQueuedPackets;
if (excess > 0) {
this.packetQueue.splice(0, excess);
}
};
private maybeReconnect = () => {
// Reconnection is driven by the worker-backed sync interval instead of a
// timer chain hanging off socket close events, so a single missed event
// or a throttled timer can never leave the session permanently offline.
if (!this.serverURL || !this.connectionOptions) {
return;
}
// A terminal protocol reject is not retryable: reconnecting would hit the
// same close(4001). Stay down until the page reloads a fresh build.
if (this.isTerminallyOutdated) {
return;