Skip to content

Commit

Permalink
Do not attempt to restart screen share tracks when re-publishing afte…
Browse files Browse the repository at this point in the history
…r reconnect (#802)

* Do not attempt to restart screen share tracks when re-publishing after reconnect

* Create green-walls-draw.md
  • Loading branch information
lukasIO authored Jul 20, 2023
1 parent eb17478 commit ea95f70
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .changeset/green-walls-draw.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"livekit-client": patch
---

Do not attempt to restart screen share tracks when re-publishing after reconnect
2 changes: 2 additions & 0 deletions src/room/Room.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1051,6 +1051,8 @@ class Room extends EventEmitter<RoomEventCallbacks> {
if (!track.isMuted) {
if (
(track instanceof LocalAudioTrack || track instanceof LocalVideoTrack) &&
track.source !== Track.Source.ScreenShare &&
track.source !== Track.Source.ScreenShareAudio &&
!track.isUserProvided
) {
// we need to restart the track before publishing, often a full reconnect
Expand Down

0 comments on commit ea95f70

Please sign in to comment.