Commit 4aea0caf authored by ale's avatar ale

Merge branch 'renovate/github.com-rs-cors-1.x' into 'master'

Update module rs/cors to v1

See merge request !17
parents fbe43bd4 26095fa4
Pipeline #10700 passed with stages
in 1 minute and 5 seconds
......@@ -16,7 +16,7 @@ require (
github.com/mssola/user_agent v0.5.2
github.com/oschwald/maxminddb-golang v0.2.0
github.com/prometheus/client_golang v1.9.0
github.com/rs/cors v0.0.0-20190613161432-33ffc0734c60
github.com/rs/cors v1.7.0
github.com/tstranex/u2f v1.0.0
go.opencensus.io v0.22.5
golang.org/x/crypto v0.0.0-20201221181555-eec23a3978ad
......
language: go
go:
- 1.9
- "1.10"
- "1.11"
- "1.12"
- tip
matrix:
allow_failures:
......
......@@ -316,10 +316,6 @@ func (c *Cors) handleActualRequest(w http.ResponseWriter, r *http.Request) {
headers := w.Header()
origin := r.Header.Get("Origin")
if r.Method == http.MethodOptions {
c.logf(" Actual request no headers added: method == %s", r.Method)
return
}
// Always set Vary, see https://github.com/rs/cors/issues/10
headers.Add("Vary", "Origin")
if origin == "" {
......
......@@ -92,7 +92,7 @@ github.com/prometheus/common/model
github.com/prometheus/procfs
github.com/prometheus/procfs/internal/fs
github.com/prometheus/procfs/internal/util
# github.com/rs/cors v0.0.0-20190613161432-33ffc0734c60
# github.com/rs/cors v1.7.0
## explicit
github.com/rs/cors
# github.com/russellhaering/goxmldsig v1.1.0
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment