From af581a470c5e07a231635704cb1d0fbf42c3176d Mon Sep 17 00:00:00 2001 From: Yishen Miao Date: Fri, 9 Feb 2024 11:48:20 -0800 Subject: [PATCH] Updating ioutil to os Updates ioutil to os. --- cdh.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cdh.go b/cdh.go index 412eee4a..4bf5ae24 100644 --- a/cdh.go +++ b/cdh.go @@ -23,8 +23,8 @@ import ( "encoding/pem" "flag" "fmt" - "io/ioutil" "log" + "os" "path/filepath" "strings" @@ -93,7 +93,7 @@ var ( func readCert(f string) (*tlsa, error) { t := NewTLSA() - data, err := ioutil.ReadFile(filepath.Join(filepath.Clean(f), "fullchain.pem")) + data, err := os.ReadFile(filepath.Join(filepath.Clean(f), "fullchain.pem")) if err != nil { return nil, err } @@ -118,7 +118,7 @@ func newDNSClient(f string) (*gcdns.Service, string, error) { var projectID string var err error - data, err := ioutil.ReadFile(filepath.Clean(f)) + data, err := os.ReadFile(filepath.Clean(f)) if err != nil { return nil, projectID, err }