Skip to content

Commit af8a1c6

Browse files
committed
Set X-Gitea-Debug header once
Instead of adding it Signed-off-by: Yarden Shoham <[email protected]>
1 parent a2f4446 commit af8a1c6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

modules/httpcache/httpcache.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ func AddCacheControlToHeader(h http.Header, maxAge time.Duration, additionalDire
3131
directives = append(directives, "max-age=0", "private", "must-revalidate")
3232

3333
// to remind users they are using non-prod setting.
34-
h.Add("X-Gitea-Debug", "RUN_MODE="+setting.RunMode)
34+
h.Set("X-Gitea-Debug", "RUN_MODE="+setting.RunMode)
3535
}
3636

3737
h.Set("Cache-Control", strings.Join(append(directives, additionalDirectives...), ", "))

0 commit comments

Comments
 (0)