Skip to content

Commit 4b0cdad

Browse files
committed
remove comment
change errorf from %v to %s
1 parent fcb5d79 commit 4b0cdad

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

pkg/transformer/kubernetes/k8sutils.go

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1266,25 +1266,21 @@ func isConfigFile(filePath string) (useConfigMap bool, readonly bool, skip bool)
12661266
func checkIsEmptyDir(filePath string) (bool, error) {
12671267
files, err := os.ReadDir(filePath)
12681268
if err != nil {
1269-
log.Errorf("ReadDir of %v failed !", filePath)
1269+
log.Errorf("ReadDir of %s failed !", filePath)
12701270
return false, err
12711271
}
12721272
if len(files) == 0 {
1273-
// is empty
12741273
return true, err
12751274
}
12761275
for _, file := range files {
12771276
if !file.IsDir() {
1278-
// not empty
12791277
return false, nil
12801278
}
1281-
// recurse directory
12821279
_, err := checkIsEmptyDir(filepath.Join(filePath, file.Name()))
12831280
if err != nil {
12841281
return false, err
12851282
}
12861283
}
1287-
// is empty
12881284
return true, nil
12891285
}
12901286

0 commit comments

Comments
 (0)