~emersion/public-inbox

kimchi: fix site configs with path in uri v1 PROPOSED

Jonathan Halmen: 1
 fix site configs with path in uri

 1 files changed, 1 insertions(+), 1 deletions(-)
Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.sr.ht/~emersion/public-inbox/patches/15414/mbox | git am -3
Learn more about email & git
View this thread in the archives

[PATCH kimchi] fix site configs with path in uri Export this patch

---
This actually makes site configs such as the following work

site foo.example.org/foo {
  file_server /path/to/index/html/
}

 directives.go | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/directives.go b/directives.go
index 7c29464..952b474 100644
--- a/directives.go
+++ b/directives.go
@@ -115,7 +115,7 @@ func parseSite(srv *Server, dir *scfg.Directive) error {
			}
		}

		ln.Mux.Handle(pattern, handler)
		ln.Mux.Handle(pattern, http.StripPrefix(path, handler))
	}
	return nil
}
-- 
2.29.2