mirror of
https://github.com/livekit/livekit.git
synced 2026-04-14 02:15:46 +00:00
correctly send participant updates
This commit is contained in:
@@ -184,6 +184,7 @@ func (c *RTCClient) Run() error {
|
||||
case *livekit.SignalResponse_Join:
|
||||
c.AppendLog("join accepted, sending offer..")
|
||||
c.localParticipant = msg.Join.Participant
|
||||
c.AppendLog("other participants", "count", len(msg.Join.OtherParticipants))
|
||||
|
||||
// Create an offer to send to the other process
|
||||
offer, err := c.PeerConn.CreateOffer(nil)
|
||||
@@ -240,6 +241,10 @@ func (c *RTCClient) Run() error {
|
||||
if err := c.PeerConn.AddICECandidate(*candidateInit); err != nil {
|
||||
return err
|
||||
}
|
||||
case *livekit.SignalResponse_Update:
|
||||
for _, p := range msg.Update.Participants {
|
||||
c.AppendLog("participant update", "id", p.Id, "state", p.State.String())
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user