Revert "debug: revert prefix hack"

This reverts commit 9002064937.
This commit is contained in:
Derrick Hammer 2024-01-24 09:51:13 -05:00
parent 9002064937
commit b3f8b483db
Signed by: pcfreak30
GPG Key ID: C997C339BE476FF2
1 changed files with 6 additions and 6 deletions

View File

@ -139,12 +139,12 @@ func replacePrefix(prefix string, h http.Handler) http.Handler {
p := strings.TrimPrefix(r.URL.Path, prefix)
rp := strings.TrimPrefix(r.URL.RawPath, prefix)
if len(p) < len(r.URL.Path) && (r.URL.RawPath == "" || len(rp) < len(r.URL.RawPath)) {
/* if len(p) == 0 {
if len(p) == 0 {
p = "/"
}
if len(rp) == 0 {
rp = "/"
}*/
}
r2 := new(http.Request)
*r2 = *r
r2.URL = new(url.URL)