cleanup deprecated package io/ioutil (#4920)

Signed-off-by: zounengren <zouyee1989@gmail.com>
This commit is contained in:
Zou Nengren
2021-10-13 15:30:31 +08:00
committed by GitHub
parent 44fcca0e0d
commit 5191959bd7
26 changed files with 53 additions and 72 deletions

View File

@@ -5,7 +5,7 @@ import (
"crypto/ecdsa"
"crypto/rsa"
"fmt"
"io/ioutil"
"io"
"os"
"path/filepath"
"strconv"
@@ -70,7 +70,7 @@ func readKeyPair(public, private string) (Pair, error) {
if err != nil {
return Pair{}, err
}
b, err := ioutil.ReadAll(rk)
b, err := io.ReadAll(rk)
if err != nil {
return Pair{}, err
}