mirror of
https://github.com/minio/minio.git
synced 2025-01-11 15:03:22 -05:00
Redirect to browser only if browser is enabled (#7914)
This commit is contained in:
parent
bce3f8237d
commit
04a152be12
@ -582,7 +582,7 @@ func writeErrorResponse(ctx context.Context, w http.ResponseWriter, err APIError
|
||||
case "AccessDenied":
|
||||
// The request is from browser and also if browser
|
||||
// is enabled we need to redirect.
|
||||
if browser {
|
||||
if browser && globalIsBrowserEnabled {
|
||||
w.Header().Set(xhttp.Location, minioReservedBucketPath+reqURL.Path)
|
||||
w.WriteHeader(http.StatusTemporaryRedirect)
|
||||
return
|
||||
|
Loading…
Reference in New Issue
Block a user