Send full update after joining when there are missed updates

This commit is contained in:
David Zhao
2021-06-19 00:14:40 -07:00
parent 38c81e5645
commit 69290c535b
4 changed files with 94 additions and 9 deletions
+4
View File
@@ -167,6 +167,10 @@ func (r *Room) Join(participant types.Participant, opts *ParticipantOptions) err
r.broadcastParticipantState(p, true)
if p.State() == livekit.ParticipantInfo_ACTIVE {
if p.UpdateAfterActive() {
_ = p.SendParticipantUpdate(ToProtoParticipants(r.GetParticipants()))
}
// subscribe participant to existing publishedTracks
r.subscribeToExistingTracks(p)