ioutil is deprecated
This commit is contained in:
parent
fdde16cf56
commit
3eb3586c0f
2
main.go
2
main.go
|
@ -12,7 +12,7 @@ import (
|
|||
)
|
||||
|
||||
var (
|
||||
version = "3.5.1"
|
||||
version = "3.5.2"
|
||||
log = logrus.New()
|
||||
)
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@ import (
|
|||
"encoding/json"
|
||||
"errors"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"os"
|
||||
|
||||
"github.com/jmoiron/sqlx"
|
||||
_ "github.com/lib/pq"
|
||||
|
@ -20,7 +20,7 @@ func GetConfig(cfg string) (db *sqlx.DB, r DjangoConfig, err error) {
|
|||
}
|
||||
}
|
||||
|
||||
jret, _ := ioutil.ReadFile(cfg)
|
||||
jret, _ := os.ReadFile(cfg)
|
||||
err = json.Unmarshal(jret, &r)
|
||||
if err != nil {
|
||||
return
|
||||
|
|
Loading…
Reference in New Issue