From 2ebb16b1bdc780880ff98d174da96c1255c598c8 Mon Sep 17 00:00:00 2001 From: Falko Habel Date: Thu, 14 Mar 2024 08:05:44 +0100 Subject: [PATCH] Better import packaging --- scripts/main.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/main.go b/scripts/main.go index d439773..9c761a2 100644 --- a/scripts/main.go +++ b/scripts/main.go @@ -5,7 +5,7 @@ import ( "bytes" "encoding/json" "fmt" - "io/ioutil" + "io" "log" "net/http" "os" @@ -35,7 +35,7 @@ func getAllPackages() { } func handleRequest(w http.ResponseWriter, r *http.Request) { // Read the request body - body, err := ioutil.ReadAll(r.Body) + body, err := io.ReadAll(r.Body) if err != nil { http.Error(w, "Error reading request body: "+err.Error(), http.StatusInternalServerError) return