From f18eb90657a1b30725223cab54381094e56b27a5 Mon Sep 17 00:00:00 2001 From: xiaoqidun Date: Wed, 30 Nov 2022 16:07:58 +0800 Subject: [PATCH] =?UTF-8?q?docs(=E6=9B=B4=E6=96=B0=E6=BC=94=E7=A4=BA):=20?= =?UTF-8?q?=E6=9B=B4=E6=96=B0=E6=BC=94=E7=A4=BA=E5=9C=B0=E5=9D=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 2 +- go.mod | 2 +- tipdw.go | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index c42e7af..859d51c 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ Golang 腾讯IP定位库 # 在线演示 -- [https://aite.xyz/tipdw](https://aite.xyz/tipdw) +- [https://aite.xyz/demo/tipdw](https://aite.xyz/demo/tipdw) # 类似项目 diff --git a/go.mod b/go.mod index bc6affa..0fcea3f 100644 --- a/go.mod +++ b/go.mod @@ -1,3 +1,3 @@ module github.com/xiaoqidun/tipdw -go 1.17 +go 1.19 diff --git a/tipdw.go b/tipdw.go index e4c09ac..14aa0e9 100644 --- a/tipdw.go +++ b/tipdw.go @@ -3,7 +3,7 @@ package tipdw import ( "encoding/json" "fmt" - "io/ioutil" + "io" "net/http" "sync" "time" @@ -63,7 +63,7 @@ func QueryIP(sk string, key string, ip string) (result Result, err error) { return } defer resp.Body.Close() - body, err := ioutil.ReadAll(resp.Body) + body, err := io.ReadAll(resp.Body) if err != nil { return }