mirror of
https://github.com/livekit/livekit.git
synced 2026-05-22 12:46:02 +00:00
Log ICE candidates on peer connection established to get remote also (#922)
This commit is contained in:
@@ -325,7 +325,6 @@ func (t *PCTransport) onICEGatheringStateChange(state webrtc.ICEGathererState) {
|
||||
return
|
||||
}
|
||||
|
||||
t.logICECandidates()
|
||||
go func() {
|
||||
t.lock.Lock()
|
||||
if t.restartAfterGathering {
|
||||
@@ -408,6 +407,7 @@ func (t *PCTransport) onPeerConnectionStateChange(state webrtc.PeerConnectionSta
|
||||
t.params.Logger.Infow("peer connection state change", "state", state.String())
|
||||
switch state {
|
||||
case webrtc.PeerConnectionStateConnected:
|
||||
t.logICECandidates()
|
||||
isInitialConnection := t.setConnectedAt(time.Now())
|
||||
if isInitialConnection {
|
||||
if t.onInitialConnected != nil {
|
||||
|
||||
Reference in New Issue
Block a user