Refactor bucket delete and bucket policy (#5580)
This commit adds the bucket delete and bucket policy functionalities to the browser. Part of rewriting the browser code to follow best practices and guidelines of React (issues #5409 and #5410) The backend code has been modified by @krishnasrinivas to prevent issue #4498 from occuring. The relevant changes have been made to the code according to the latest commit and the unit tests in the backend. This commit also addresses issue #5449.
This commit is contained in:
committed by
Harshavardhana
parent
416841869a
commit
a6adef0bdf
@@ -280,7 +280,7 @@ func (h minioReservedBucketHandler) ServeHTTP(w http.ResponseWriter, r *http.Req
|
||||
default:
|
||||
// For all other requests reject access to reserved
|
||||
// buckets
|
||||
bucketName, _ := urlPath2BucketObjectName(r.URL)
|
||||
bucketName, _ := urlPath2BucketObjectName(r.URL.Path)
|
||||
if isMinioReservedBucket(bucketName) || isMinioMetaBucket(bucketName) {
|
||||
writeErrorResponse(w, ErrAllAccessDisabled, r.URL)
|
||||
return
|
||||
@@ -439,7 +439,7 @@ var notimplementedObjectResourceNames = map[string]bool{
|
||||
|
||||
// Resource handler ServeHTTP() wrapper
|
||||
func (h resourceHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
|
||||
bucketName, objectName := urlPath2BucketObjectName(r.URL)
|
||||
bucketName, objectName := urlPath2BucketObjectName(r.URL.Path)
|
||||
|
||||
// If bucketName is present and not objectName check for bucket level resource queries.
|
||||
if bucketName != "" && objectName == "" {
|
||||
|
||||
Reference in New Issue
Block a user