@ -40,6 +40,8 @@ const (
maxObjectSize = 1024 * 1024 * 1024 * 5
maxObjectSize = 1024 * 1024 * 1024 * 5
// minimum Part size for multipart upload is 5MB
// minimum Part size for multipart upload is 5MB
minPartSize = 1024 * 1024 * 5
minPartSize = 1024 * 1024 * 5
// maximum Part ID for multipart upload is 10000 (Acceptable values range from 1 to 10000 inclusive)
maxPartID = 10000
)
)
// isMaxObjectSize - verify if max object size
// isMaxObjectSize - verify if max object size
@ -52,6 +54,11 @@ func isMinAllowedPartSize(size int64) bool {
return size >= minPartSize
return size >= minPartSize
}
}
// isMaxPartNumber - Check if part ID is greater than the maximum allowed ID.
func isMaxPartID ( partID int ) bool {
return partID > maxPartID
}
func contains ( stringList [ ] string , element string ) bool {
func contains ( stringList [ ] string , element string ) bool {
for _ , e := range stringList {
for _ , e := range stringList {
if e == element {
if e == element {