b2: fix inconsistent listings and rclone check
This was caused by re-using a variable for the results of a JSON unmarshal and the unmarshaller picking up existing entries. See https://forum.rclone.org/t/check-command-gives-unreliable-results/
This commit is contained in:
parent
0ce34be41d
commit
1d42a343d2
1 changed files with 1 additions and 1 deletions
2
b2/b2.go
2
b2/b2.go
|
@ -467,7 +467,6 @@ func (f *Fs) list(dir string, level int, prefix string, limit int, hidden bool,
|
|||
if prefix != "" {
|
||||
request.StartFileName = prefix
|
||||
}
|
||||
var response api.ListFileNamesResponse
|
||||
opts := rest.Opts{
|
||||
Method: "POST",
|
||||
Path: "/b2_list_file_names",
|
||||
|
@ -476,6 +475,7 @@ func (f *Fs) list(dir string, level int, prefix string, limit int, hidden bool,
|
|||
opts.Path = "/b2_list_file_versions"
|
||||
}
|
||||
for {
|
||||
var response api.ListFileNamesResponse
|
||||
err := f.pacer.Call(func() (bool, error) {
|
||||
resp, err := f.srv.CallJSON(&opts, &request, &response)
|
||||
return f.shouldRetry(resp, err)
|
||||
|
|
Loading…
Reference in a new issue