mirror of
https://github.com/tailscale/tailscale.git
synced 2026-09-22 03:25:16 -04:00
control/controlclient: trim /32 suffix a bit more succinctly
This commit is contained in:
1 parent
19d95e095a
commit
894e3bfc96
1 file changed
+1
-4
@@ -75,10 +75,7 @@ func (nm *NetworkMap) Concise() string {
|
||||
for _, p := range nm.Peers {
|
||||
aip := make([]string, len(p.AllowedIPs))
|
||||
for i, a := range p.AllowedIPs {
|
||||
s := fmt.Sprint(a)
|
||||
if strings.HasSuffix(s, "/32") {
|
||||
s = s[0 : len(s)-3]
|
||||
}
|
||||
s := strings.TrimSuffix(fmt.Sprint(a), "/32")
|
||||
aip[i] = s
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user