mirror of
https://github.com/minio/minio.git
synced 2024-12-24 06:05:55 -05:00
Fix force bucket deletion in distributed mode (#12659)
storageRESTForceDelete is not always passed by client, use r.URL().Query instead. Co-authored-by: Anis Elleuch <anis@min.io>
This commit is contained in:
parent
bab72f6887
commit
c8cf4c5eb8
@ -282,7 +282,7 @@ func (s *storageRESTServer) DeleteVolHandler(w http.ResponseWriter, r *http.Requ
|
||||
}
|
||||
vars := mux.Vars(r)
|
||||
volume := vars[storageRESTVolume]
|
||||
forceDelete := vars[storageRESTForceDelete] == "true"
|
||||
forceDelete := r.URL.Query().Get(storageRESTForceDelete) == "true"
|
||||
err := s.storage.DeleteVol(r.Context(), volume, forceDelete)
|
||||
if err != nil {
|
||||
s.writeErrorResponse(w, err)
|
||||
|
Loading…
Reference in New Issue
Block a user