mirror of
https://github.com/XIU2/CloudflareSpeedTest.git
synced 2026-04-26 00:07:36 +08:00
更新 import "io/ioutil" -> "io"
This commit is contained in:
4
main.go
4
main.go
@@ -3,7 +3,7 @@ package main
|
|||||||
import (
|
import (
|
||||||
"flag"
|
"flag"
|
||||||
"fmt"
|
"fmt"
|
||||||
"io/ioutil"
|
"io"
|
||||||
"net/http"
|
"net/http"
|
||||||
"os"
|
"os"
|
||||||
"runtime"
|
"runtime"
|
||||||
@@ -162,7 +162,7 @@ func checkUpdate() {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
// 读取资源数据 body: []byte
|
// 读取资源数据 body: []byte
|
||||||
body, err := ioutil.ReadAll(res.Body)
|
body, err := io.ReadAll(res.Body)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user