Enabling visits notification

This commit is contained in:
collin 2026-04-19 22:35:10 +02:00
parent 7146046ee0
commit e4930efff9

View file

@ -160,11 +160,11 @@ func (h *Handler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
getStaticFile("./client/favicon.ico", "image/png", w)
case r.Method == "GET" && r.URL.Path == "/":
// Temporarily disable visit notifications because it's just spam
// visit := h.visits.HandleVisit(r.Header.Get("X-Forwarded-For"))
// if visit != nil {
// h.ntfy.PublishNewVisitNotification(visit)
// }
visit := h.visits.HandleVisit(r.Header.Get("X-Forwarded-For"))
if visit != nil {
h.ntfy.PublishNewVisitNotification(visit)
}
getStaticFile("./client/index.html", "text/html", w)
case r.Method == "GET" && r.URL.Path == "/rsvp":