diff options
author | clsr <clsr@clsr.net> | 2016-10-15 20:09:16 +0200 |
---|---|---|
committer | clsr <clsr@clsr.net> | 2016-10-15 20:09:16 +0200 |
commit | cf4adc19b165f848714cd6e6e073cea97baf483f (patch) | |
tree | 36b7ca1281296252c50733a077514d3a257d1d62 | |
parent | 35b0c989f7a33b09a33abf9c7c8f65d08ebdfaa6 (diff) | |
download | gomf-0.4.3.tar.gz gomf-0.4.3.zip |
Fix Expires headerv0.4.3
-rw-r--r-- | api.go | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -41,7 +41,7 @@ func handleFile(w http.ResponseWriter, r *http.Request) { } w.Header().Set("X-Content-Type-Options", "nosniff") w.Header().Set("Last-Modified", modtime.UTC().Format(http.TimeFormat)) - w.Header().Set("Expires", modtime.UTC().Add(time.Hour*24*30).Format(http.TimeFormat)) + w.Header().Set("Expires", time.Now().UTC().Add(time.Hour*24*30).Format(http.TimeFormat)) w.Header().Set("Cache-Control", "max-age=2592000") w.Header().Set("ETag", "\"sha1:"+hash+"\"") //io.Copy(w, f) |