Cleanup - audit
This commit is contained in:
@@ -95,14 +95,6 @@ func (a *App) switchActiveRelay() {
|
||||
a.relay = best
|
||||
}
|
||||
|
||||
func preferredEndpoint(v4, v6 netip.AddrPort) netip.AddrPort {
|
||||
// We always prefer v4 since all peers can connect to IPv4 addresses.
|
||||
if v4.IsValid() {
|
||||
return v4
|
||||
}
|
||||
return v6
|
||||
}
|
||||
|
||||
func roleFor(selfIsPublic bool, selfIP netip.Addr, peerIsPublic bool, peerVPNIP netip.Addr) control.Role {
|
||||
if !selfIsPublic && peerIsPublic {
|
||||
return control.Client
|
||||
|
||||
Reference in New Issue
Block a user