Skip to content

Commit

Permalink
certdb: replace uses of deprecated io/ioutil
Browse files Browse the repository at this point in the history
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
  • Loading branch information
thaJeztah committed Nov 20, 2022
1 parent c9e5b44 commit 7025962
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions certdb/dbconf/db_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package dbconf
import (
"encoding/json"
"errors"
"io/ioutil"
"os"

cferr "github.com/cloudflare/cfssl/errors"
"github.com/cloudflare/cfssl/log"
Expand All @@ -26,7 +26,7 @@ func LoadFile(path string) (cfg *DBConfig, err error) {
}

var body []byte
body, err = ioutil.ReadFile(path)
body, err = os.ReadFile(path)
if err != nil {
return nil, cferr.Wrap(cferr.PolicyError, cferr.InvalidPolicy, errors.New("could not read configuration file"))
}
Expand Down

0 comments on commit 7025962

Please sign in to comment.