From 0fb2d3c6c92927f0b75c8b93b2aa4361e284b082 Mon Sep 17 00:00:00 2001 From: Bryan Frimin Date: Mon, 2 Feb 2026 12:12:35 +0100 Subject: [PATCH] Fix missing cache-control when cache mactch Signed-off-by: Bryan Frimin --- pkg/server/statichandler/statichandler.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pkg/server/statichandler/statichandler.go b/pkg/server/statichandler/statichandler.go index a81b07eba..26c10b488 100644 --- a/pkg/server/statichandler/statichandler.go +++ b/pkg/server/statichandler/statichandler.go @@ -183,6 +183,13 @@ func (s *Server) ServeSPA(w http.ResponseWriter, r *http.Request) { w.Header().Set("Cache-Control", "public, max-age=3600") } + if matchETag := r.Header.Get("If-None-Match"); matchETag != "" { + if matchETag == quotedETag { + w.WriteHeader(http.StatusNotModified) + return + } + } + http.FileServer(s.spaFS).ServeHTTP(w, r) }