Skip to content

Commit 77a52e7

Browse files
committed
config: replace uses of deprecated io/ioutil
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
1 parent 7c1b358 commit 77a52e7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

config/config.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import (
88
"encoding/json"
99
"errors"
1010
"fmt"
11-
"io/ioutil"
11+
"os"
1212
"regexp"
1313
"strconv"
1414
"strings"
@@ -699,7 +699,7 @@ func LoadFile(path string) (*Config, error) {
699699
return nil, cferr.Wrap(cferr.PolicyError, cferr.InvalidPolicy, errors.New("invalid path"))
700700
}
701701

702-
body, err := ioutil.ReadFile(path)
702+
body, err := os.ReadFile(path)
703703
if err != nil {
704704
return nil, cferr.Wrap(cferr.PolicyError, cferr.InvalidPolicy, errors.New("could not read configuration file"))
705705
}

0 commit comments

Comments
 (0)