summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorThomas Voss <mail@thomasvoss.com> 2024-08-07 01:45:08 +0200
committerThomas Voss <mail@thomasvoss.com> 2024-08-07 01:45:08 +0200
commitb9adf8ce89d4bc1453d13d365bdee678a62406b1 (patch)
tree88b6f4e08718bfb18c4ea2b78b2c96288c5e0b0e
parent634525b0cbc7e61cb4278a07c2269ecd2b336be2 (diff)
Add a comment
-rw-r--r--main.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/main.go b/main.go
index b987ef2..0597e83 100644
--- a/main.go
+++ b/main.go
@@ -42,6 +42,7 @@ func main() {
func finalHandler(w http.ResponseWriter, r *http.Request) {
p := r.Context().Value(middleware.PrinterKey).(i18n.Printer)
+ /* Strip trailing slash from the URL */
path := r.URL.Path
if path != "/" && path[len(path)-1] == '/' {
path = path[:len(path)-1]