mirror of
https://github.com/minio/minio.git
synced 2025-11-09 13:39:46 -05:00
Return Owner information in ListObjectV2 only when fetch-owner is specified (#2654)
This commit is contained in:
committed by
Harshavardhana
parent
e6abfb3b67
commit
8acf4d112a
@@ -706,12 +706,15 @@ func getListObjectsV1URL(endPoint, bucketName string, maxKeys string) string {
|
||||
}
|
||||
|
||||
// return URL for listing objects in the bucket with V2 API.
|
||||
func getListObjectsV2URL(endPoint, bucketName string, maxKeys string) string {
|
||||
func getListObjectsV2URL(endPoint, bucketName string, maxKeys string, fetchOwner string) string {
|
||||
queryValue := url.Values{}
|
||||
queryValue.Set("list-type", "2") // Enables list objects V2 URL.
|
||||
if maxKeys != "" {
|
||||
queryValue.Set("max-keys", maxKeys)
|
||||
}
|
||||
if fetchOwner != "" {
|
||||
queryValue.Set("fetch-owner", fetchOwner)
|
||||
}
|
||||
return makeTestTargetURL(endPoint, bucketName, "", queryValue)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user