From 4c0acba62d93f94e7dea504f03682cdf9970294d Mon Sep 17 00:00:00 2001 From: Ramon de Klein Date: Thu, 25 Apr 2024 18:27:27 +0200 Subject: [PATCH] Fixes an internal error while force-deleting a bucket (#19614) --- cmd/bucket-handlers.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/bucket-handlers.go b/cmd/bucket-handlers.go index 2edca90b9..9822e3e7e 100644 --- a/cmd/bucket-handlers.go +++ b/cmd/bucket-handlers.go @@ -1661,7 +1661,7 @@ func (api objectAPIHandlers) DeleteBucketHandler(w http.ResponseWriter, r *http. writeErrorResponse(ctx, w, errorCodes.ToAPIErr(ErrMethodNotAllowed), r.URL) return } - case rcfg.HasActiveRules("", true): + case rcfg != nil && rcfg.HasActiveRules("", true): writeErrorResponse(ctx, w, errorCodes.ToAPIErr(ErrMethodNotAllowed), r.URL) return }