multi: repleace ioutil.ReadAll
This commit is contained in:
1 parent
8ce3622792
commit
619c8f4eb8
8 files changed
+12
-16
No files matched your search
@@ -8,6 +8,7 @@ import (
|
||||
"encoding/hex"
|
||||
"errors"
|
||||
"fmt"
|
||||
"io"
|
||||
"io/ioutil"
|
||||
"net"
|
||||
"os"
|
||||
@@ -2006,7 +2007,7 @@ func extractBtcdRPCParams(btcdConfigPath string) (string, string, error) {
|
||||
|
||||
// With the file open extract the contents of the configuration file so
|
||||
// we can attempt to locate the RPC credentials.
|
||||
configContents, err := ioutil.ReadAll(btcdConfigFile)
|
||||
configContents, err := io.ReadAll(btcdConfigFile)
|
||||
if err != nil {
|
||||
return "", "", err
|
||||
}
|
||||
@@ -2056,7 +2057,7 @@ func extractBitcoindRPCParams(networkName, bitcoindDataDir, bitcoindConfigPath,
|
||||
|
||||
// With the file open extract the contents of the configuration file so
|
||||
// we can attempt to locate the RPC credentials.
|
||||
configContents, err := ioutil.ReadAll(bitcoindConfigFile)
|
||||
configContents, err := io.ReadAll(bitcoindConfigFile)
|
||||
if err != nil {
|
||||
return "", "", "", "", err
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user