File tree Expand file tree Collapse file tree 3 files changed +5
-7
lines changed
Expand file tree Collapse file tree 3 files changed +5
-7
lines changed Original file line number Diff line number Diff line change 44 "crypto/tls"
55 "crypto/x509"
66 "fmt"
7- "io/ioutil "
7+ "os "
88 "strings"
99 "time"
1010
@@ -132,7 +132,7 @@ func NewConnector(config ConnectorConfig) (*Connector, error) {
132132 if config .TLS .CACertPath != "" {
133133 log .Debugf ("Adding CA certs from %s" , config .TLS .CACertPath )
134134 caCertPool = x509 .NewCertPool ()
135- caCertContents , err := ioutil .ReadFile (config .TLS .CACertPath )
135+ caCertContents , err := os .ReadFile (config .TLS .CACertPath )
136136 if err != nil {
137137 return nil , err
138138 }
Original file line number Diff line number Diff line change @@ -3,7 +3,6 @@ package cli
33import (
44 "context"
55 "fmt"
6- "io/ioutil"
76 "os"
87 "path/filepath"
98 "regexp"
@@ -177,7 +176,7 @@ func (c *CLIRunner) BootstrapTopics(
177176
178177 if isNew || overwrite {
179178 log .Infof ("Writing config to %s" , outputPath )
180- err = ioutil .WriteFile (outputPath , []byte (yamlStr ), 0644 )
179+ err = os .WriteFile (outputPath , []byte (yamlStr ), 0644 )
181180 if err != nil {
182181 return err
183182 }
Original file line number Diff line number Diff line change 44 "bytes"
55 "encoding/json"
66 "errors"
7- "io/ioutil"
87 "os"
98 "path/filepath"
109 "regexp"
@@ -18,7 +17,7 @@ var sep = regexp.MustCompile("(?:^|\\s*\n)---\\s*")
1817
1918// LoadClusterFile loads a ClusterConfig from a path to a YAML file.
2019func LoadClusterFile (path string , expandEnv bool ) (ClusterConfig , error ) {
21- contents , err := ioutil .ReadFile (path )
20+ contents , err := os .ReadFile (path )
2221 if err != nil {
2322 return ClusterConfig {}, err
2423 }
@@ -50,7 +49,7 @@ func LoadClusterBytes(contents []byte) (ClusterConfig, error) {
5049
5150// LoadTopicsFile loads one or more TopicConfigs from a path to a YAML file.
5251func LoadTopicsFile (path string ) ([]TopicConfig , error ) {
53- contents , err := ioutil .ReadFile (path )
52+ contents , err := os .ReadFile (path )
5453 if err != nil {
5554 return nil , err
5655 }
You can’t perform that action at this time.
0 commit comments