From 4359978ef22a22ddd5a19adf18cbc80cb44244fb Mon Sep 17 00:00:00 2001 From: Taras Madan Date: Thu, 23 Feb 2023 14:28:18 +0100 Subject: all: ioutil is deprecated in go1.19 (#3718) --- dashboard/dashapi/dashapi.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'dashboard/dashapi/dashapi.go') diff --git a/dashboard/dashapi/dashapi.go b/dashboard/dashapi/dashapi.go index d3ee7bae3..be1cd2fd5 100644 --- a/dashboard/dashapi/dashapi.go +++ b/dashboard/dashapi/dashapi.go @@ -11,7 +11,6 @@ import ( "encoding/json" "fmt" "io" - "io/ioutil" "net/http" "net/mail" "net/url" @@ -808,7 +807,7 @@ func (dash *Dashboard) queryImpl(method string, req, reply interface{}) error { } defer resp.Body.Close() if resp.StatusCode != http.StatusOK { - data, _ := ioutil.ReadAll(resp.Body) + data, _ := io.ReadAll(resp.Body) return fmt.Errorf("request failed with %v: %s", resp.Status, data) } if reply != nil { -- cgit mrf-deployment