Apply normalization to paths before passing to list for index

This commit is contained in:
Seednode 2023-10-03 09:28:00 -05:00
parent 900b59155b
commit 13440f6a4e
2 changed files with 6 additions and 6 deletions

View File

@ -250,13 +250,13 @@ func walkPath(path string, fileChannel chan<- string, stats *scanStatsChannels,
var skipFiles = false
if files < MinFileCount || files > MaxFileCount {
if files <= MaxFileCount && files >= MinFileCount {
stats.directoriesMatched <- 1
} else {
stats.filesSkipped <- files
stats.directoriesSkipped <- 1
skipFiles = true
} else {
stats.directoriesMatched <- 1
}
for _, node := range nodes {
@ -270,7 +270,7 @@ func walkPath(path string, fileChannel chan<- string, stats *scanStatsChannels,
defer func() {
wg.Done()
}()
err = walkPath(fullPath, fileChannel, stats, formats)
err := walkPath(fullPath, fileChannel, stats, formats)
if err != nil {
errorChannel <- err
@ -297,7 +297,7 @@ func walkPath(path string, fileChannel chan<- string, stats *scanStatsChannels,
return
}
fileChannel <- fullPath
fileChannel <- path
stats.filesMatched <- 1
}()

View File

@ -12,7 +12,7 @@ import (
)
const (
ReleaseVersion string = "2.2.0"
ReleaseVersion string = "2.2.1"
)
var (