diff --git a/.gitignore b/.gitignore index ad0d2a5b..8512dcba 100644 --- a/.gitignore +++ b/.gitignore @@ -30,6 +30,7 @@ Thumbs.db .env config.json config.db +.tool-versions # 决策日志 decision_logs/ @@ -41,3 +42,4 @@ web/node_modules/ node_modules/ web/dist/ web/.vite/ +web/yarn.lock diff --git a/market/data.go b/market/data.go index cd40be75..5a40f172 100644 --- a/market/data.go +++ b/market/data.go @@ -3,7 +3,7 @@ package market import ( "encoding/json" "fmt" - "io/ioutil" + "io" "math" "net/http" "strconv" @@ -299,7 +299,7 @@ func getOpenInterestData(symbol string) (*OIData, error) { } defer resp.Body.Close() - body, err := ioutil.ReadAll(resp.Body) + body, err := io.ReadAll(resp.Body) if err != nil { return nil, err } @@ -332,7 +332,7 @@ func getFundingRate(symbol string) (float64, error) { } defer resp.Body.Close() - body, err := ioutil.ReadAll(resp.Body) + body, err := io.ReadAll(resp.Body) if err != nil { return 0, err }