aboutsummaryrefslogtreecommitdiff
path: root/cmd/dendrite-demo-yggdrasil/yggconn/node.go
diff options
context:
space:
mode:
Diffstat (limited to 'cmd/dendrite-demo-yggdrasil/yggconn/node.go')
-rw-r--r--cmd/dendrite-demo-yggdrasil/yggconn/node.go5
1 files changed, 2 insertions, 3 deletions
diff --git a/cmd/dendrite-demo-yggdrasil/yggconn/node.go b/cmd/dendrite-demo-yggdrasil/yggconn/node.go
index d93272e2..ff3c73ec 100644
--- a/cmd/dendrite-demo-yggdrasil/yggconn/node.go
+++ b/cmd/dendrite-demo-yggdrasil/yggconn/node.go
@@ -20,7 +20,6 @@ import (
"encoding/hex"
"encoding/json"
"fmt"
- "io/ioutil"
"log"
"net"
"os"
@@ -69,7 +68,7 @@ func Setup(instanceName, storageDirectory, peerURI string) (*Node, error) {
yggfile := fmt.Sprintf("%s/%s-yggdrasil.conf", storageDirectory, instanceName)
if _, err := os.Stat(yggfile); !os.IsNotExist(err) {
- yggconf, e := ioutil.ReadFile(yggfile)
+ yggconf, e := os.ReadFile(yggfile)
if e != nil {
panic(err)
}
@@ -88,7 +87,7 @@ func Setup(instanceName, storageDirectory, peerURI string) (*Node, error) {
if err != nil {
panic(err)
}
- if e := ioutil.WriteFile(yggfile, j, 0600); e != nil {
+ if e := os.WriteFile(yggfile, j, 0600); e != nil {
n.log.Printf("Couldn't write private key to file '%s': %s\n", yggfile, e)
}