Allow creating new note without trailing slash

This commit is contained in:
Maximilian Friedersdorff 2025-06-24 22:14:32 +01:00
parent c82db192e1
commit 551dcf5905

View file

@ -19,6 +19,7 @@ func GetRoutes(prefix string) *http.ServeMux {
myurls = urls.URLs{
Prefix: prefix,
URLs: map[string]urls.URL{
"view_": {Path: "/{note}", Protocol: "GET", Handler: view},
"view": {Path: "/{note}/", Protocol: "GET", Handler: view},
"delete": {Path: "/{note}/delete/", Protocol: "GET", Handler: delete},
"edit": {Path: "/{note}/edit/", Protocol: "GET", Handler: edit},