Skip to content

Commit

Permalink
catch more instances
Browse files Browse the repository at this point in the history
  • Loading branch information
lukasIO committed Oct 26, 2023
1 parent fa6074a commit 737565e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/room/Room.ts
Original file line number Diff line number Diff line change
Expand Up @@ -611,8 +611,8 @@ class Room extends (EventEmitter as new () => TypedEmitter<RoomEventCallbacks>)
}

if (abortController.signal.aborted) {
await this.engine.close();
this.recreateEngine();
this.handleDisconnect(this.options.stopLocalTrackOnUnpublish);
throw new ConnectionError(`Connection attempt aborted`);
}

Expand All @@ -622,8 +622,8 @@ class Room extends (EventEmitter as new () => TypedEmitter<RoomEventCallbacks>)
abortController,
);
} catch (e) {
await this.engine.close();
this.recreateEngine();
this.handleDisconnect(this.options.stopLocalTrackOnUnpublish);
throw e;
}

Expand Down

0 comments on commit 737565e

Please sign in to comment.