mirror of
https://github.com/rclone/rclone
synced 2025-01-05 06:26:34 +01:00
acd: filter out bogus children Amazon reports sometimes
This commit is contained in:
parent
718694d5ee
commit
2243b065e8
@ -392,6 +392,17 @@ func (f *Fs) listAll(dirID string, title string, directoriesOnly bool, filesOnly
|
||||
if *node.Status != statusAvailable {
|
||||
continue
|
||||
}
|
||||
// Ignore bogus nodes Amazon Drive sometimes reports
|
||||
hasValidParent := false
|
||||
for _, parent := range node.Parents {
|
||||
if parent == dirID {
|
||||
hasValidParent = true
|
||||
break
|
||||
}
|
||||
}
|
||||
if !hasValidParent {
|
||||
continue
|
||||
}
|
||||
// Store the nodes up in case we have to retry the listing
|
||||
out = append(out, node)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user