summaryrefslogtreecommitdiff
path: root/service
diff options
context:
space:
mode:
Diffstat (limited to 'service')
-rwxr-xr-xservice/reload/213977608/file.txt0
-rwxr-xr-xservice/reload/423382903/file.txt0
-rw-r--r--service/reload/watcher.go11
3 files changed, 1 insertions, 10 deletions
diff --git a/service/reload/213977608/file.txt b/service/reload/213977608/file.txt
new file mode 100755
index 00000000..e69de29b
--- /dev/null
+++ b/service/reload/213977608/file.txt
diff --git a/service/reload/423382903/file.txt b/service/reload/423382903/file.txt
new file mode 100755
index 00000000..e69de29b
--- /dev/null
+++ b/service/reload/423382903/file.txt
diff --git a/service/reload/watcher.go b/service/reload/watcher.go
index 027d2d0d..721495c3 100644
--- a/service/reload/watcher.go
+++ b/service/reload/watcher.go
@@ -177,15 +177,6 @@ func (w *Watcher) retrieveFilesSingle(serviceName, path string) (map[string]os.F
// so, we will add files with goto pattern
outer:
for i := 0; i < len(fileInfoList); i++ {
- var pathToFile string
- // BCE check elimination
- // https://go101.org/article/bounds-check-elimination.html
- if len(fileInfoList) != 0 && len(fileInfoList) >= i {
- pathToFile = filepath.Join(pathToFile, fileInfoList[i].Name())
- } else {
- return nil, errors.New("file info list len")
- }
-
// if file in ignored --> continue
if _, ignored := w.watcherConfigs[serviceName].ignored[path]; ignored {
continue
@@ -199,7 +190,7 @@ outer:
}
}
- filesList[pathToFile] = fileInfoList[i]
+ filesList[fileInfoList[i].Name()] = fileInfoList[i]
}
return filesList, nil