mirror of
https://github.com/rclone/rclone.git
synced 2024-11-26 02:14:42 +01:00
qingstor: upgrade to v3 SDK and fix listing loop
This commit is contained in:
parent
a72ef7ca0e
commit
c2050172aa
@ -24,9 +24,9 @@ import (
|
|||||||
"github.com/rclone/rclone/fs/fshttp"
|
"github.com/rclone/rclone/fs/fshttp"
|
||||||
"github.com/rclone/rclone/fs/hash"
|
"github.com/rclone/rclone/fs/hash"
|
||||||
"github.com/rclone/rclone/fs/walk"
|
"github.com/rclone/rclone/fs/walk"
|
||||||
qsConfig "github.com/yunify/qingstor-sdk-go/config"
|
qsConfig "github.com/yunify/qingstor-sdk-go/v3/config"
|
||||||
qsErr "github.com/yunify/qingstor-sdk-go/request/errors"
|
qsErr "github.com/yunify/qingstor-sdk-go/v3/request/errors"
|
||||||
qs "github.com/yunify/qingstor-sdk-go/service"
|
qs "github.com/yunify/qingstor-sdk-go/v3/service"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Register with Fs
|
// Register with Fs
|
||||||
@ -582,9 +582,12 @@ func (f *Fs) list(ctx context.Context, dir string, recurse bool, fn listFn) erro
|
|||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if resp.HasMore != nil && !*resp.HasMore {
|
||||||
|
break
|
||||||
|
}
|
||||||
// Use NextMarker if set, otherwise use last Key
|
// Use NextMarker if set, otherwise use last Key
|
||||||
if resp.NextMarker == nil || *resp.NextMarker == "" {
|
if resp.NextMarker == nil || *resp.NextMarker == "" {
|
||||||
//marker = resp.Keys[len(resp.Keys)-1].Key
|
fs.Errorf(f, "Expecting NextMarker but didn't find one")
|
||||||
break
|
break
|
||||||
} else {
|
} else {
|
||||||
marker = resp.NextMarker
|
marker = resp.NextMarker
|
||||||
|
@ -15,7 +15,7 @@ import (
|
|||||||
|
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
"github.com/rclone/rclone/fs"
|
"github.com/rclone/rclone/fs"
|
||||||
qs "github.com/yunify/qingstor-sdk-go/service"
|
qs "github.com/yunify/qingstor-sdk-go/v3/service"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
Loading…
Reference in New Issue
Block a user