Add no-cache header to force revalidation on page loads
This commit is contained in:
2
main.go
2
main.go
@@ -102,6 +102,8 @@ func main() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func handleStatic(w http.ResponseWriter, r *http.Request) {
|
func handleStatic(w http.ResponseWriter, r *http.Request) {
|
||||||
|
w.Header().Set("Cache-Control", "no-cache")
|
||||||
|
|
||||||
path := r.URL.Path
|
path := r.URL.Path
|
||||||
if path == "/" {
|
if path == "/" {
|
||||||
path = "/index.html"
|
path = "/index.html"
|
||||||
|
|||||||
Reference in New Issue
Block a user