Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions pkg/transformer/kubernetes/k8sutils.go
Original file line number Diff line number Diff line change
Expand Up @@ -1250,7 +1250,7 @@ func isConfigFile(filePath string) (useConfigMap bool, readonly bool, skip bool)
return
}

if !fi.Mode().IsRegular() { // is dir
if fi.Mode().IsDir() { // is dir
isDirEmpty, err := checkIsEmptyDir(filePath)
if err != nil {
log.Warnf("Failed to check if the directory is empty: %v", err)
Expand Down Expand Up @@ -1278,7 +1278,7 @@ func checkIsEmptyDir(filePath string) (bool, error) {
if !file.IsDir() {
return false, nil
}
_, err := checkIsEmptyDir(file.Name())
_, err := checkIsEmptyDir(filepath.Join(filePath, file.Name()))
if err != nil {
return false, err
}
Expand Down