diff --git a/pkg/util/fs_util.go b/pkg/util/fs_util.go index fa7a5db7d..81a268c09 100644 --- a/pkg/util/fs_util.go +++ b/pkg/util/fs_util.go @@ -121,8 +121,8 @@ func DeleteFilesystem() error { logrus.Info("Deleting filesystem...") return filepath.Walk(constants.RootDir, func(path string, info os.FileInfo, _ error) error { if CheckWhitelist(path) { - if ! isExist(path) { - logrus.Debugf("Path %s whitelisted, but not exists", path) + if !isExist(path) { + logrus.Debugf("Path %s whitelisted, but not exists", path) return nil } if info.IsDir() { @@ -141,7 +141,8 @@ func DeleteFilesystem() error { return os.RemoveAll(path) }) } -// isExists returns tru if path exists + +// isExists returns true if path exists func isExist(path string) bool { if _, err := os.Stat(path); err == nil { return true