Skip to content

Commit

Permalink
Fix formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
caseydavenport committed Nov 27, 2024
1 parent 318b171 commit bbd2919
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions cni-plugin/pkg/install/install.go
Original file line number Diff line number Diff line change
Expand Up @@ -306,8 +306,8 @@ func isValidJSON(s string) error {

// Convert permission string to fileMode for testing purposes
func stringToFileMode(permString string) (os.FileMode, error) {
perm, err := strconv.ParseUint(permString, 8, 32)
return os.FileMode(perm), err
perm, err := strconv.ParseUint(permString, 8, 32)
return os.FileMode(perm), err
}

func writeCNIConfig(c config) {
Expand Down Expand Up @@ -390,9 +390,9 @@ func writeCNIConfig(c config) {
permString := getEnv("TEST_FILE_PERMISSION", "0600")
logrus.Infof("CNI config file permission is set to %s\n", permString)
perm, err := stringToFileMode(permString)
if err != nil {
logrus.Fatal(err)
}
if err != nil {
logrus.Fatal(err)
}

name := getEnv("CNI_CONF_NAME", "10-calico.conflist")
path := winutils.GetHostPath(fmt.Sprintf("/host/etc/cni/net.d/%s", name))
Expand Down

0 comments on commit bbd2919

Please sign in to comment.