mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-08-25 21:21:33 +02:00
multi: repleace ioutil.ReadFile
This commit is contained in:
3
lnd.go
3
lnd.go
@@ -8,7 +8,6 @@ import (
|
||||
"context"
|
||||
"errors"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"net"
|
||||
"net/http"
|
||||
"net/http/pprof"
|
||||
@@ -83,7 +82,7 @@ func AdminAuthOptions(cfg *Config, skipMacaroons bool) ([]grpc.DialOption,
|
||||
// Get the admin macaroon if macaroons are active.
|
||||
if !skipMacaroons && !cfg.NoMacaroons {
|
||||
// Load the admin macaroon file.
|
||||
macBytes, err := ioutil.ReadFile(cfg.AdminMacPath)
|
||||
macBytes, err := os.ReadFile(cfg.AdminMacPath)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("unable to read macaroon "+
|
||||
"path (check the network setting!): %v", err)
|
||||
|
Reference in New Issue
Block a user