Update cache control for web assets
The commit [1] introduced the `cache-control` header field with the value
`no-cache`. This enforces any cache to revalidate. Apparently this does
not prohibit *FireFox* from caching the assets. `no-cache, no-store,
must-revalidate` does by prohibiting to even save anything of the
request.
[1] c3850708c1
This commit is contained in:
parent
02f14775e5
commit
9cc00323ca
|
@ -40,7 +40,7 @@ func serveAsset(w http.ResponseWriter, req *http.Request, fp string) {
|
|||
return
|
||||
}
|
||||
|
||||
w.Header().Set("Cache-Control", "no-cache")
|
||||
w.Header().Set("Cache-Control", "no-cache, no-store, must-revalidate")
|
||||
http.ServeContent(w, req, info.Name(), info.ModTime(), bytes.NewReader(file))
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue