mirror of
https://github.com/pgsty/minio.git
synced 2026-08-10 16:23:28 +03:00
Add region to gcs gateway example
This commit is contained in:
committed by
Harshavardhana
parent
5c78415b31
commit
4430085981
@@ -658,7 +658,10 @@ func (api gatewayAPIHandlers) PutBucketHandler(w http.ResponseWriter, r *http.Re
|
||||
// reads body which has been read already. So only validating
|
||||
// region here.
|
||||
serverRegion := serverConfig.GetRegion()
|
||||
if serverRegion != location {
|
||||
if serverRegion == "" {
|
||||
// we will only validate the region
|
||||
// when the region has been explicitely set
|
||||
} else if serverRegion != location {
|
||||
writeErrorResponse(w, ErrInvalidRegion, r.URL)
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user