mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-06-21 00:20:50 +00:00
[BRANDING] add X-Forgejo-* headers
(cherry picked from commit0a3388f93f
) (cherry picked from commit7eba0a440a
) (cherry picked from commiteb9646c7ef
) (cherry picked from commitf1972578f5
) Conflicts: (cherry picked from commit7f96222fb4
)
This commit is contained in:
parent
dd545aa077
commit
e3c7c9fe7b
6 changed files with 25 additions and 2 deletions
|
@ -32,6 +32,7 @@ func SetCacheControlInHeader(h http.Header, maxAge time.Duration, additionalDire
|
|||
|
||||
// to remind users they are using non-prod setting.
|
||||
h.Set("X-Gitea-Debug", "RUN_MODE="+setting.RunMode)
|
||||
h.Set("X-Forgejo-Debug", "RUN_MODE="+setting.RunMode)
|
||||
}
|
||||
|
||||
h.Set("Cache-Control", strings.Join(append(directives, additionalDirectives...), ", "))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue