Rewrite WebRTC peer connection constructor

This commit is contained in:
Alexey Khit
2023-03-06 17:15:13 +03:00
parent 03a4393ce3
commit 1e83dc85f7
3 changed files with 11 additions and 10 deletions
+2 -2
View File
@@ -40,7 +40,7 @@ func asyncClient(url string) (streamer.Producer, error) {
}()
// 2. Create PeerConnection
pc, err := newPeerConnection(false)
pc, err := PeerConnection(true)
if err != nil {
log.Error().Err(err).Caller().Send()
return nil, err
@@ -125,7 +125,7 @@ func asyncClient(url string) (streamer.Producer, error) {
// syncClient - support WebRTC-HTTP Egress Protocol (WHEP)
func syncClient(url string) (streamer.Producer, error) {
// 2. Create PeerConnection
pc, err := newPeerConnection(false)
pc, err := PeerConnection(true)
if err != nil {
log.Error().Err(err).Caller().Send()
return nil, err