1
1
mirror of https://github.com/go-gitea/gitea synced 2025-07-13 14:07:20 +00:00

add bool for performance

This commit is contained in:
silverwind
2024-04-03 01:52:56 +02:00
parent bd4559c4cd
commit d5c7b6d502
4 changed files with 6 additions and 3 deletions

View File

@ -236,7 +236,7 @@ func APIContexter() func(http.Handler) http.Handler {
httpcache.SetCacheControlInHeader(ctx.Resp.Header(), 0, "no-transform")
if setting.XFrameOptions != "false" {
if setting.UseXFrameOptions {
ctx.Resp.Header().Set(`X-Frame-Options`, setting.XFrameOptions)
}