Browse Source

Move fallbacks at the end

Ettore Di Giacinto 4 years ago
parent
commit
eeb466a786
1 changed files with 2 additions and 1 deletions
  1. 2 1
      pkg/edgevpn/connection.go

+ 2 - 1
pkg/edgevpn/connection.go

@@ -20,7 +20,6 @@ var defaultLibp2pOptions = []libp2p.Option{
 	libp2p.EnableAutoRelay(),
 	libp2p.EnableAutoRelay(),
 	libp2p.EnableNATService(),
 	libp2p.EnableNATService(),
 	libp2p.NATPortMap(),
 	libp2p.NATPortMap(),
-	libp2p.FallbackDefaults,
 }
 }
 
 
 func (e *EdgeVPN) Host() host.Host {
 func (e *EdgeVPN) Host() host.Host {
@@ -80,6 +79,8 @@ func (e *EdgeVPN) genHost(ctx context.Context) (host.Host, error) {
 		opts = append(opts, libp2p.NoSecurity)
 		opts = append(opts, libp2p.NoSecurity)
 	}
 	}
 
 
+	opts = append(opts, libp2p.FallbackDefaults)
+
 	return libp2p.New(ctx, opts...)
 	return libp2p.New(ctx, opts...)
 }
 }