chore(all): replace net.IP with netip.Addr

This commit is contained in:
Quentin McGaw
2023-05-20 19:58:18 +00:00
parent 00ee6ff9a7
commit 0a29337c3b
91 changed files with 525 additions and 590 deletions

View File

@@ -5,8 +5,8 @@ import (
"encoding/json"
"errors"
"fmt"
"net"
"net/http"
"net/netip"
"strconv"
"time"
)
@@ -32,10 +32,10 @@ type groupData struct {
}
type serverData struct {
Hostname string `json:"hostname"`
IP net.IP `json:"ip"`
IP2 net.IP `json:"ip2"`
IP3 net.IP `json:"ip3"`
Hostname string `json:"hostname"`
IP netip.Addr `json:"ip"`
IP2 netip.Addr `json:"ip2"`
IP3 netip.Addr `json:"ip3"`
}
func fetchAPI(ctx context.Context, client *http.Client) (