s3: KeyCount is zero

fix https://github.com/chrislusf/seaweedfs/issues/1741
This commit is contained in:
Chris Lu 2021-01-11 03:50:45 -08:00
parent 2c7148cd55
commit 8a7302ce37

View File

@ -71,7 +71,7 @@ func (s3a *S3ApiServer) ListObjectsV2Handler(w http.ResponseWriter, r *http.Requ
ContinuationToken: continuationToken,
Delimiter: response.Delimiter,
IsTruncated: response.IsTruncated,
KeyCount: len(response.Contents),
KeyCount: len(response.Contents) + len(response.CommonPrefixes),
MaxKeys: response.MaxKeys,
NextContinuationToken: response.NextMarker,
Prefix: response.Prefix,