From a7d010334c962ce9f73f7cecad1fd20e7ab23e76 Mon Sep 17 00:00:00 2001 From: Ryan Hamilton Date: Mon, 10 Jan 2022 15:14:32 -0600 Subject: [PATCH] Fix non pointer reference I broke this not realizing I needed to use a pointer reference. --- main.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main.go b/main.go index b9e4c8b..ea52574 100644 --- a/main.go +++ b/main.go @@ -14,7 +14,8 @@ func main() { utils.ParseFlags(&ip, &properties, &detail) // 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 result := ipapi.GetProperties(data, properties, detail) @@ -22,5 +23,4 @@ func main() { // Print result with PrintOut utils.PrintOut(result) utils.Exit(0) - }