From 9421fdd0eb97d5126eb7d0ad092925141eb37f35 Mon Sep 17 00:00:00 2001 From: Fang Yuan Date: Wed, 9 Nov 2022 15:56:51 +0800 Subject: [PATCH] replace ioutil usage Signed-off-by: Fang Yuan --- .../digibank/application-go/business/addtowallet.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/commercial-paper/organization/digibank/application-go/business/addtowallet.go b/commercial-paper/organization/digibank/application-go/business/addtowallet.go index 65ff4178..bc3bddf0 100644 --- a/commercial-paper/organization/digibank/application-go/business/addtowallet.go +++ b/commercial-paper/organization/digibank/application-go/business/addtowallet.go @@ -1,7 +1,6 @@ package business import ( - "io/ioutil" "log" "os" "path/filepath" @@ -42,11 +41,11 @@ func AddUser() error { privateKeyPath := filepath.Join(credPath, "keystore", "priv_sk") log.Println("privateKeyPath: " + privateKeyPath) // read the certificate pem - certificate, err := ioutil.ReadFile(filepath.Clean(certPath)) + certificate, err := os.ReadFile(filepath.Clean(certPath)) if err != nil { return err } - privateKey, err := ioutil.ReadFile(filepath.Clean(privateKeyPath)) + privateKey, err := os.ReadFile(filepath.Clean(privateKeyPath)) if err != nil { return err }