mirror of
https://gitlab.com/comunic/ComunicRTCProxy
synced 2024-12-26 13:38:55 +00:00
Reformat code
This commit is contained in:
parent
1b88b51c23
commit
85ddd9691d
6
relay.go
6
relay.go
@ -228,6 +228,9 @@ func newCall(mainOffer receivedSignal, r *activeRelay) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Close peer connection
|
||||||
|
defer mainPeerConnection.Close()
|
||||||
|
|
||||||
// Check if the connection is closed
|
// Check if the connection is closed
|
||||||
mainPeerConnection.OnConnectionStateChange(func(s webrtc.PeerConnectionState) {
|
mainPeerConnection.OnConnectionStateChange(func(s webrtc.PeerConnectionState) {
|
||||||
if s == webrtc.PeerConnectionStateClosed {
|
if s == webrtc.PeerConnectionStateClosed {
|
||||||
@ -236,9 +239,6 @@ func newCall(mainOffer receivedSignal, r *activeRelay) {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
// Close peer connection
|
|
||||||
defer mainPeerConnection.Close()
|
|
||||||
|
|
||||||
// Forward ice candidates
|
// Forward ice candidates
|
||||||
mainPeerConnection.OnICECandidate(func(c *webrtc.ICECandidate) {
|
mainPeerConnection.OnICECandidate(func(c *webrtc.ICECandidate) {
|
||||||
if c == nil || r.closed {
|
if c == nil || r.closed {
|
||||||
|
Loading…
Reference in New Issue
Block a user