mirror of
https://github.com/Kugelschieber/marvinblum.git
synced 2026-01-18 06:40:27 +00:00
Updated dependencies and integrated Pirsch v1.2.0.
This commit is contained in:
10
main.go
10
main.go
@@ -60,7 +60,7 @@ func logEnvConfig() {
|
||||
|
||||
func serveAbout() http.HandlerFunc {
|
||||
return func(w http.ResponseWriter, r *http.Request) {
|
||||
tracker.Hit(r)
|
||||
tracker.Hit(r, nil)
|
||||
tplCache.Render(w, "about.html", struct {
|
||||
Articles []emvi.Article
|
||||
}{
|
||||
@@ -71,14 +71,14 @@ func serveAbout() http.HandlerFunc {
|
||||
|
||||
func serveLegal() http.HandlerFunc {
|
||||
return func(w http.ResponseWriter, r *http.Request) {
|
||||
tracker.Hit(r)
|
||||
tracker.Hit(r, nil)
|
||||
tplCache.Render(w, "legal.html", nil)
|
||||
}
|
||||
}
|
||||
|
||||
func serveBlogPage() http.HandlerFunc {
|
||||
return func(w http.ResponseWriter, r *http.Request) {
|
||||
tracker.Hit(r)
|
||||
tracker.Hit(r, nil)
|
||||
tplCache.Render(w, "blog.html", struct {
|
||||
Articles map[int][]emvi.Article
|
||||
}{
|
||||
@@ -105,7 +105,7 @@ func serveBlogArticle() http.HandlerFunc {
|
||||
}
|
||||
|
||||
// track the hit if the article was found, otherwise we don't care
|
||||
tracker.Hit(r)
|
||||
tracker.Hit(r, nil)
|
||||
|
||||
tplCache.RenderWithoutCache(w, "article.html", struct {
|
||||
Title string
|
||||
@@ -121,7 +121,7 @@ func serveBlogArticle() http.HandlerFunc {
|
||||
|
||||
func serveTracking() http.HandlerFunc {
|
||||
return func(w http.ResponseWriter, r *http.Request) {
|
||||
tracker.Hit(r)
|
||||
tracker.Hit(r, nil)
|
||||
start, _ := strconv.Atoi(r.URL.Query().Get("start"))
|
||||
|
||||
if start > 365 {
|
||||
|
||||
Reference in New Issue
Block a user