aboutsummaryrefslogtreecommitdiff
path: root/watch.go
diff options
context:
space:
mode:
authorTim Keller <tjk@tjkeller.xyz>2026-05-16 22:04:14 -0500
committerTim Keller <tjk@tjkeller.xyz>2026-05-16 22:04:14 -0500
commit1316aa7ca5e1668bbb7967264540bff3c8dbef86 (patch)
treecc6a4121c13d31a96060e3fa9103ed314578c8cc /watch.go
parent3bfeed5a50cd1bb405cbe145611410fa4f628413 (diff)
downloadembedtube-1316aa7ca5e1668bbb7967264540bff3c8dbef86.tar.xz
embedtube-1316aa7ca5e1668bbb7967264540bff3c8dbef86.zip
new api implemented server-side
Diffstat (limited to 'watch.go')
-rw-r--r--watch.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/watch.go b/watch.go
index 8352e62..81f0d86 100644
--- a/watch.go
+++ b/watch.go
@@ -26,8 +26,8 @@ func renderWatchTemplate(w http.ResponseWriter, id string) {
}
/* routes */
-func setupRoutesWatch() {
- http.HandleFunc("/watch", func(w http.ResponseWriter, r *http.Request) {
+func registerRoutesWatch(mux *http.ServeMux) {
+ mux.HandleFunc("/watch", func(w http.ResponseWriter, r *http.Request) {
id := r.URL.Query().Get("v")
renderWatchTemplate(w, id)
})