mirror of
https://github.com/laoxong/nofx.git
synced 2026-06-04 09:58:22 +08:00
Updates dependencies and ignores files
Updates dependencies by replacing ioutil with io. Adds .tool-versions and web/yarn.lock to .gitignore.
This commit is contained in:
@@ -30,6 +30,7 @@ Thumbs.db
|
|||||||
.env
|
.env
|
||||||
config.json
|
config.json
|
||||||
config.db
|
config.db
|
||||||
|
.tool-versions
|
||||||
|
|
||||||
# 决策日志
|
# 决策日志
|
||||||
decision_logs/
|
decision_logs/
|
||||||
@@ -41,3 +42,4 @@ web/node_modules/
|
|||||||
node_modules/
|
node_modules/
|
||||||
web/dist/
|
web/dist/
|
||||||
web/.vite/
|
web/.vite/
|
||||||
|
web/yarn.lock
|
||||||
|
|||||||
+3
-3
@@ -3,7 +3,7 @@ package market
|
|||||||
import (
|
import (
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
"fmt"
|
"fmt"
|
||||||
"io/ioutil"
|
"io"
|
||||||
"math"
|
"math"
|
||||||
"net/http"
|
"net/http"
|
||||||
"strconv"
|
"strconv"
|
||||||
@@ -299,7 +299,7 @@ func getOpenInterestData(symbol string) (*OIData, error) {
|
|||||||
}
|
}
|
||||||
defer resp.Body.Close()
|
defer resp.Body.Close()
|
||||||
|
|
||||||
body, err := ioutil.ReadAll(resp.Body)
|
body, err := io.ReadAll(resp.Body)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
@@ -332,7 +332,7 @@ func getFundingRate(symbol string) (float64, error) {
|
|||||||
}
|
}
|
||||||
defer resp.Body.Close()
|
defer resp.Body.Close()
|
||||||
|
|
||||||
body, err := ioutil.ReadAll(resp.Body)
|
body, err := io.ReadAll(resp.Body)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return 0, err
|
return 0, err
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user