feat(security): #314 include all proposed security headers
All checks were successful
Build Docker Image / Build-Docker-Image (push) Successful in 43s
Build and Push Docker Image / Build-And-Push-Docker-Image (push) Successful in 47s

This commit was merged in pull request #315.
This commit is contained in:
2024-12-12 21:37:23 +01:00
parent 60fe2789cc
commit 1ad694ce2b
8 changed files with 48 additions and 85 deletions

View File

@@ -3,14 +3,11 @@ package middleware
import (
"net/http"
"strings"
"me-fit/log"
)
func CacheControl(next http.Handler) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
path := r.URL.Path
log.Info("path: %v", path)
cached := false
if strings.HasPrefix(path, "/static") {