Browse Source
Update weed/s3api/s3api_object_handlers.go
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
pull/6987/head
Chris Lu
3 months ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
2 additions and
2 deletions
-
weed/s3api/s3api_object_handlers.go
|
@ -392,9 +392,9 @@ func setUserMetadataKeyToLowercase(resp *http.Response) { |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
func captureCORSHeaders(w http.ResponseWriter, corsHeaders []string) map[string]string { |
|
|
|
|
|
|
|
|
func captureCORSHeaders(w http.ResponseWriter, headersToCapture []string) map[string]string { |
|
|
captured := make(map[string]string) |
|
|
captured := make(map[string]string) |
|
|
for _, corsHeader := range corsHeaders { |
|
|
|
|
|
|
|
|
for _, corsHeader := range headersToCapture { |
|
|
if value := w.Header().Get(corsHeader); value != "" { |
|
|
if value := w.Header().Get(corsHeader); value != "" { |
|
|
captured[corsHeader] = value |
|
|
captured[corsHeader] = value |
|
|
} |
|
|
} |
|
|