From eccc0f20f01d0176cfbcc031233b549b6013ddac Mon Sep 17 00:00:00 2001 From: Elizabeth Hunt Date: Tue, 2 Apr 2024 09:40:08 -0600 Subject: set path precedence for / rather than /static/ --- api/serve.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'api') diff --git a/api/serve.go b/api/serve.go index 2cddcfd..f71001d 100644 --- a/api/serve.go +++ b/api/serve.go @@ -78,7 +78,7 @@ func MakeServer(argv *args.Arguments, dbConn *sql.DB) *http.Server { mux := http.NewServeMux() fileServer := http.FileServer(http.Dir(argv.StaticPath)) - mux.Handle("/static/", http.StripPrefix("/static/", CacheControlMiddleware(fileServer, 3600))) + mux.Handle("GET /static/", http.StripPrefix("/static/", CacheControlMiddleware(fileServer, 3600))) makeRequestContext := func() *RequestContext { return &RequestContext{ -- cgit v1.2.3-70-g09d2