From b25c89c7c554526379aa8b1a7c4c216d91d31843 Mon Sep 17 00:00:00 2001 From: John Blyberg Date: Tue, 20 Feb 2024 12:04:52 -0500 Subject: [PATCH] Update y-websocket.js --- src/y-websocket.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/y-websocket.js b/src/y-websocket.js index f68fb21..2640e1d 100644 --- a/src/y-websocket.js +++ b/src/y-websocket.js @@ -399,7 +399,7 @@ export class WebsocketProvider extends Observable { } clearInterval(this._checkInterval) this.disconnect() - if (typeof process !== 'undefined') { + if (env.isNode && typeof process !== 'undefined') { process.off('exit', this._exitHandler) } this.awareness.off('update', this._awarenessUpdateHandler)