main: ioutil.ReadFile is deprecated
Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
This commit is contained in:
parent
e4bbd71991
commit
1bda3de425
1 changed files with 1 additions and 2 deletions
3
main.go
3
main.go
|
@ -4,7 +4,6 @@ import (
|
|||
"context"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"os"
|
||||
|
||||
"github.com/mattn/go-mastodon"
|
||||
|
@ -44,7 +43,7 @@ func main() {
|
|||
ClientSecret: "asfdasdfasfd",
|
||||
AccessToken: "asdfasdfadfasfd",
|
||||
}
|
||||
buf, err := ioutil.ReadFile(ctx.String("config"))
|
||||
buf, err := os.ReadFile(ctx.String("config"))
|
||||
if err == nil {
|
||||
tmpconfig := mastodon.Config{}
|
||||
err := json.Unmarshal(buf, &tmpconfig)
|
||||
|
|
Loading…
Reference in a new issue