allow clearing FIFO config as fallback (#14338)

FIFO is already removed, for users who upgrade are allowed to clear their configs.
This commit is contained in:
Harshavardhana
2022-02-17 12:49:46 -08:00
committed by GitHub
parent 93af4a4864
commit af8f563ed3
2 changed files with 11 additions and 0 deletions

View File

@@ -71,6 +71,11 @@ func (a adminAPIHandlers) PutBucketQuotaConfigHandler(w http.ResponseWriter, r *
return
}
if quotaConfig.Type == "fifo" {
writeErrorResponseJSON(ctx, w, errorCodes.ToAPIErr(ErrInvalidRequest), r.URL)
return
}
if err = globalBucketMetadataSys.Update(ctx, bucket, bucketQuotaConfigFile, data); err != nil {
writeErrorResponse(ctx, w, toAPIError(ctx, err), r.URL)
return