Send Partscount only when partnumber is specified (#9793)

Fixes #9789
This commit is contained in:
kannappanr
2020-06-10 09:22:15 -07:00
committed by GitHub
parent 3d3b75fb8d
commit 2c372a9894
5 changed files with 25 additions and 7 deletions

View File

@@ -1310,6 +1310,11 @@ func (web *webAPIHandlers) Download(w http.ResponseWriter, r *http.Request) {
}
}
// Set Parts Count Header
if opts.PartNumber > 0 && len(objInfo.Parts) > 0 {
setPartsCountHeaders(w, objInfo)
}
if err = setObjectHeaders(w, objInfo, nil); err != nil {
writeWebErrorResponse(w, err)
return