Add comments

This commit is contained in:
root
2021-07-11 18:38:05 +00:00
parent 2189c6b174
commit 7fe2a016e4

View File

@@ -282,6 +282,7 @@ func (e mainEnv) setupRouter() *httprouter.Router {
} else if strings.HasSuffix(r.URL.Path, ".svg") {
w.Header().Set("Content-Type", "image/svg+xml")
}
// next step: https://www.sanarias.com/blog/115LearningHTTPcachinginGo
w.Header().Set("Cache-Control", "public, max-age=7776000")
w.WriteHeader(200)
w.Write([]byte(data))