Fix file write out-of-band timing issue

This commit is contained in:
Joe Lim committed 2024-04-10 23:03:14 +10:00
1 parent 9c0afc56c4
commit 089c540d75
1 file changed
+3 -1
+3 -1
View File
@@ -645,7 +645,9 @@ func (app *app) updateFile(path string, add bool) {
}
if add {
allFiles = append(allFiles, newFile(path))
if _, err := os.Stat(path); err == nil {
allFiles = append(allFiles, newFile(path))
}
}
dir.allFiles = allFiles