From f839444d3b59ff19547cfedaf073944664688198 Mon Sep 17 00:00:00 2001 From: Matthew Knight Date: Tue, 17 Feb 2026 16:12:47 -0800 Subject: [PATCH] Disable static file directory listing Fixes #28 Co-Authored-By: Claude Opus 4.6 --- internal/handlers/public/routes.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/handlers/public/routes.go b/internal/handlers/public/routes.go index 1aa6cc7..e67f8fa 100644 --- a/internal/handlers/public/routes.go +++ b/internal/handlers/public/routes.go @@ -41,7 +41,7 @@ func NewRouter(deps Dependencies) *gin.Engine { c.String(http.StatusOK, "ok") }) - r.Static("/static", "web/static") + r.StaticFS("/static", gin.Dir("web/static", false)) webhookHandler := &WebhookHandler{deps: deps} r.POST("/webhooks/forgejo/:repoSlug", webhookHandler.HandleForgejoWebhook)