[tor-commits] [snowflake/master] Simplify NewWebRTCDialer.
dcf at torproject.org
dcf at torproject.org
Tue Jan 28 03:58:52 UTC 2020
commit db1ba4791b101b7a83060261bb44769dd7db8e25
Author: David Fifield <david at bamsoftware.com>
Date: Tue Dec 24 20:03:11 2019 -0700
Simplify NewWebRTCDialer.
---
client/lib/rendezvous.go | 9 ++-------
1 file changed, 2 insertions(+), 7 deletions(-)
diff --git a/client/lib/rendezvous.go b/client/lib/rendezvous.go
index fef0eb5..d117ebc 100644
--- a/client/lib/rendezvous.go
+++ b/client/lib/rendezvous.go
@@ -125,13 +125,8 @@ type WebRTCDialer struct {
}
func NewWebRTCDialer(broker *BrokerChannel, iceServers []webrtc.ICEServer) *WebRTCDialer {
- var config webrtc.Configuration
- if iceServers != nil {
- config = webrtc.Configuration{
- ICEServers: iceServers,
- }
- } else {
- config = webrtc.Configuration{}
+ config := webrtc.Configuration{
+ ICEServers: iceServers,
}
return &WebRTCDialer{
BrokerChannel: broker,
More information about the tor-commits
mailing list