Feature: filter by country, region and city for Privado

This commit is contained in:
Quentin McGaw
2021-05-09 00:51:34 +00:00
parent a7a5cca8dd
commit 8407542600
10 changed files with 467 additions and 268 deletions

View File

@@ -78,13 +78,16 @@ func (s *NordvpnServer) String() string {
}
type PrivadoServer struct {
IP net.IP `json:"ip"`
Country string `json:"country"`
Region string `json:"region"`
City string `json:"city"`
Hostname string `json:"hostname"`
IP net.IP `json:"ip"`
}
func (s *PrivadoServer) String() string {
return fmt.Sprintf("{Hostname: %q, IP: %s}",
s.Hostname, goStringifyIP(s.IP))
return fmt.Sprintf("{Country: %q, Region: %q, City: %q, Hostname: %q, IP: %s}",
s.Country, s.Region, s.City, s.Hostname, goStringifyIP(s.IP))
}
type PIAServer struct {