metainfo: Fix listing paths (#645)
This commit is contained in:
parent
5cdb03515f
commit
17519a7532
@ -108,6 +108,11 @@ func (db *DB) ListObjects(ctx context.Context, bucket string, options storj.List
|
||||
return storj.ObjectList{}, errClass.New("invalid direction %d", options.Direction)
|
||||
}
|
||||
|
||||
// TODO: remove this hack-fix of specifying the last key
|
||||
if options.Cursor == "" && (options.Direction == storj.Before || options.Direction == storj.Backward) {
|
||||
endBefore = "\x7f\x7f\x7f\x7f\x7f\x7f\x7f"
|
||||
}
|
||||
|
||||
items, more, err := objects.List(ctx, options.Prefix, startAfter, endBefore, options.Recursive, options.Limit, meta.All)
|
||||
if err != nil {
|
||||
return storj.ObjectList{}, err
|
||||
|
Loading…
Reference in New Issue
Block a user