Skip to content

Commit

Permalink
presence auto-re-enter: use ErrorInfo.cause
Browse files Browse the repository at this point in the history
Co-authored-by: Owen Pearson <[email protected]>
  • Loading branch information
SimonWoolf and owenpearson authored Nov 7, 2024
1 parent 26c1d86 commit cf94386
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/common/lib/client/realtimepresence.ts
Original file line number Diff line number Diff line change
Expand Up @@ -441,8 +441,7 @@ class RealtimePresence extends EventEmitter {
// RTP17g1: suppress id if the connId has changed
const id = (entry.connectionId === connId) ? entry.id : undefined;
this._enterOrUpdateClient(id, entry.clientId, entry.data, 'enter').catch((err) => {
const msg = 'Presence auto-re-enter failed: ' + err.toString();
const wrappedErr = new ErrorInfo(msg, 91004, 400);
const wrappedErr = new ErrorInfo('Presence auto re-enter failed', 91004, 400, err);
Logger.logAction(this.logger, Logger.LOG_ERROR, 'RealtimePresence._ensureMyMembersPresent()', msg);
const change = new ChannelStateChange(this.channel.state, this.channel.state, true, false, wrappedErr);
this.channel.emit('update', change);
Expand Down

0 comments on commit cf94386

Please sign in to comment.