Zachary Rice 3 anni fa
parent
commit
61ee7c58cc
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. 1 1
      detect/detect.go

+ 1 - 1
detect/detect.go

@@ -335,7 +335,7 @@ func (d *Detector) DetectFiles(source string) ([]report.Finding, error) {
 				if err != nil {
 				if err != nil {
 					return err
 					return err
 				}
 				}
-				if fInfo.Name() == ".git" {
+				if fInfo.Name() == ".git" && fInfo.IsDir() {
 					return filepath.SkipDir
 					return filepath.SkipDir
 				}
 				}
 				if fInfo.Mode().IsRegular() {
 				if fInfo.Mode().IsRegular() {