Archived
lib/db: Add index to track locally needed files (#4958)
To optimize WithNeed, which is called for the local device whenever an index update is received. No tracking for remote devices to conserve db space, as WithNeed is only queried for completion.
This commit is contained in:
1 parent
d3a02a1663
commit
5baa432906
10 files changed
+440
-203
No files matched your search
@@ -346,7 +346,7 @@ func pullInvalidIgnored(t *testing.T, ft config.FolderType) {
|
||||
expected := map[string]struct{}{invIgn: {}, ign: {}, ignExisting: {}}
|
||||
for _, f := range fs {
|
||||
if _, ok := expected[f.Name]; !ok {
|
||||
t.Fatalf("Unexpected file %v was added to index", f.Name)
|
||||
t.Errorf("Unexpected file %v was added to index", f.Name)
|
||||
}
|
||||
if !f.Invalid {
|
||||
t.Errorf("File %v wasn't marked as invalid", f.Name)
|
||||
|
||||
Reference in new issue
Block a user