This commit is contained in:
hoteas
2018-05-29 17:39:37 +00:00
parent 5cbef50464
commit 9ff8f50fb9
3 changed files with 36 additions and 74 deletions
+3 -1
View File
@@ -302,8 +302,10 @@ func (this *Application) handler(w http.ResponseWriter, req *http.Request) {
if value, ok := mimeMaps[mimeStr]; ok {
header.Set("Content-Type", value)
}
if this.Config.GetInt("debug")!=1{
header.Set("Cache-Control", "public")
}
header.Set("Cache-Control", "public")
//w.Write(data)
http.ServeFile(w, req, path)