Skip to content

Commit

Permalink
better error message when WS is not supported
Browse files Browse the repository at this point in the history
  • Loading branch information
FZambia committed Feb 16, 2025
1 parent 8de6b05 commit 103414b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/centrifuge.ts
Original file line number Diff line number Diff line change
Expand Up @@ -677,7 +677,7 @@ export class Centrifuge extends (EventEmitter as new () => TypedEventEmitter<Cli
websocket: websocket
});
if (!this._transport.supported()) {
throw new Error('WebSocket not available');
throw new Error('WebSocket constructor not found, make sure it is available globally or passed as a dependency in Centrifuge options');
}
}
} else {
Expand Down

0 comments on commit 103414b

Please sign in to comment.