Fix non pointer reference

I broke this not realizing I needed to use a pointer reference.
This commit is contained in:
2022-01-10 15:14:32 -06:00
parent ec14e26e83
commit a7d010334c

View File

@@ -14,7 +14,8 @@ func main() {
utils.ParseFlags(&ip, &properties, &detail) utils.ParseFlags(&ip, &properties, &detail)
// Use the IP-API to lookup the IP address // Use the IP-API to lookup the IP address
data := ipapi.Lookup(ip, properties) data, err := ipapi.Lookup(&ip, &properties)
utils.HandleError(err)
// Format the data to a string // Format the data to a string
result := ipapi.GetProperties(data, properties, detail) result := ipapi.GetProperties(data, properties, detail)
@@ -22,5 +23,4 @@ func main() {
// Print result with PrintOut // Print result with PrintOut
utils.PrintOut(result) utils.PrintOut(result)
utils.Exit(0) utils.Exit(0)
} }