Merge branch 'shyam' into shyam-frontend

This commit is contained in:
Sai Sanjay
2024-06-01 11:00:32 +05:30
committed by GitHub
5 changed files with 33 additions and 2 deletions

View File

@@ -337,7 +337,13 @@ func main() {
rw.Header().Add("Content-Type", "text/html; charset=utf-8")
web.RenderTemplate(rw, "privacy.tmpl", &web.Page{Title: "Privacy", Build: buildInfo})
})
// r.NotFoundHandler
r.NotFoundHandler = http.HandlerFunc(func(rw http.ResponseWriter, r *http.Request) {
rw.WriteHeader(http.StatusNotFound)
rw.Header().Add("Content-Type", "text/html; charset=utf-8")
web.RenderTemplate(rw, "404.tmpl", &web.Page{Title: "Page not found", Build: buildInfo})
})
-
secured := r.PathPrefix("/").Subrouter()