diff --git a/honk.go b/honk.go index 1669eff..341d5f6 100644 --- a/honk.go +++ b/honk.go @@ -1374,7 +1374,6 @@ func serve() { getters.HandleFunc("/u/{name:[[:alnum:]]+}/followers", emptiness) getters.HandleFunc("/u/{name:[[:alnum:]]+}/following", emptiness) getters.HandleFunc("/a", avatate) - getters.HandleFunc("/t", showconvoy) getters.HandleFunc("/d/{xid:[[:alnum:].]+}", servefile) getters.HandleFunc("/emu/{xid:[[:alnum:]_.-]+}", serveemu) getters.HandleFunc("/meme/{xid:[[:alnum:]_.-]+}", servememe) @@ -1405,6 +1404,7 @@ func serve() { loggedin.HandleFunc("/h", showhonker) loggedin.HandleFunc("/c/{name:[[:alnum:]]+}", showcombo) loggedin.HandleFunc("/c", showcombos) + loggedin.HandleFunc("/t", showconvoy) loggedin.Handle("/savehonker", login.CSRFWrap("savehonker", http.HandlerFunc(savehonker))) err = http.Serve(listener, mux) diff --git a/views/honk.html b/views/honk.html index 7148bb3..211d0e7 100644 --- a/views/honk.html +++ b/views/honk.html @@ -1,4 +1,5 @@
+{{ $bonkcsrf := .BonkCSRF }} {{ with .Honk }}
avatar @@ -17,9 +18,11 @@ in reply to: {{ .RID }} {{ end }} {{ end }}
- -convoy: {{ .Convoy }} - +{{ if $bonkcsrf }} +convoy: {{ .Convoy }} +{{ else }} +convoy: {{ .Convoy }} +{{ end }}

{{ .HTML }} @@ -44,7 +47,7 @@ convoy: {{ .Convoy }} {{ end }}

{{ end }} -{{ if .BonkCSRF }} +{{ if $bonkcsrf }}

Actions