Skip to content

Commit

Permalink
Replace deprecated 'ioutil' with io
Browse files Browse the repository at this point in the history
  • Loading branch information
manschwa committed Feb 12, 2024
1 parent c51e29f commit fba06a7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import (
"encoding/json"
"errors"
"io/fs"
"io/ioutil"
"io"
"log"
"net/http"
"os"
Expand Down Expand Up @@ -123,7 +123,7 @@ func setupRouter() *gin.Engine {
c.JSON(http.StatusBadGateway, nil)
return
}
bodyText, err := ioutil.ReadAll(resp.Body)
bodyText, err := io.ReadAll(resp.Body)
s := string(bodyText)
var result AgentStateResult
json.Unmarshal([]byte(s), &result)
Expand Down

0 comments on commit fba06a7

Please sign in to comment.