don't cache avatar in debugmode
This commit is contained in:
parent
493f5fc8f8
commit
066a6806bd
1 changed files with 3 additions and 1 deletions
4
web.go
4
web.go
|
@ -2105,7 +2105,9 @@ func avatate(w http.ResponseWriter, r *http.Request) {
|
|||
}
|
||||
n := r.FormValue("a")
|
||||
a := genAvatar(n)
|
||||
w.Header().Set("Cache-Control", "max-age="+somedays())
|
||||
if !debugMode {
|
||||
w.Header().Set("Cache-Control", "max-age="+somedays())
|
||||
}
|
||||
w.Write(a)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue