summaryrefslogtreecommitdiff
path: root/pages/pages.go
diff options
context:
space:
mode:
authorRené 'Necoro' Neumann <necoro@necoro.eu>2024-10-17 18:07:11 +0200
committerRené 'Necoro' Neumann <necoro@necoro.eu>2024-10-17 18:07:11 +0200
commit70031d8971136583647125d967ace7b9c831ed00 (patch)
tree9b3b329b366ab9e5637de3dabb2a64c46bfc76f0 /pages/pages.go
parent650053446d18424500ae6330b5ad0da81fa86373 (diff)
downloadgosten-70031d8971136583647125d967ace7b9c831ed00.tar.gz
gosten-70031d8971136583647125d967ace7b9c831ed00.tar.bz2
gosten-70031d8971136583647125d967ace7b9c831ed00.zip
Save User as part of the context
Diffstat (limited to 'pages/pages.go')
-rw-r--r--pages/pages.go9
1 files changed, 2 insertions, 7 deletions
diff --git a/pages/pages.go b/pages/pages.go
index eb7a3f6..0f03cdd 100644
--- a/pages/pages.go
+++ b/pages/pages.go
@@ -5,10 +5,7 @@ import (
)
func Init() Page {
- return simple(index, func(r *http.Request, uid int32) string {
- u, _ := Q.GetUserById(r.Context(), uid)
- return u.Name
- })
+ return simple(index())
}
func Recur() Page {
@@ -20,7 +17,5 @@ func Categories() Page {
}
func NotFound() http.HandlerFunc {
- return func(w http.ResponseWriter, r *http.Request) {
- render(notfound(r.RequestURI), w, r)
- }
+ return render(notfound())
}