redirect /foo/ -> /foo iff /foo exists
1 file changed, 5 insertions(+), 0 deletions(-)
M internal/storage/files/reader.go → internal/storage/files/reader.go
@@ -88,6 +88,11 @@ case !strings.HasSuffix(path, "/") && r.files[path+"/"] != nil: cPath, differs = path+"/", true + case strings.HasSuffix(path, "/"): + if cPath, differs = strings.CutSuffix(path, "/"); differs && r.files[cPath] != nil { + return cPath, differs + } + } return cPath, differs