adjustment to file search
This commit is contained in:
BIN
bin/nwg-drawer
BIN
bin/nwg-drawer
Binary file not shown.
@@ -275,7 +275,8 @@ func walk(path string, d fs.DirEntry, e error) error {
|
|||||||
}
|
}
|
||||||
//if !d.IsDir() {
|
//if !d.IsDir() {
|
||||||
parts := strings.Split(path, "/")
|
parts := strings.Split(path, "/")
|
||||||
fileName := parts[len(parts)-1]
|
//fileName := parts[len(parts)-1]
|
||||||
|
fileName := strings.Join(parts[4:], "/")
|
||||||
if strings.Contains(strings.ToLower(fileName), strings.ToLower(phrase)) {
|
if strings.Contains(strings.ToLower(fileName), strings.ToLower(phrase)) {
|
||||||
fileSearchResults = append(fileSearchResults, path)
|
fileSearchResults = append(fileSearchResults, path)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user