scheme from conf

This commit is contained in:
bel
2026-01-31 16:33:07 -07:00
parent c283999b1a
commit 9f67c8c22c

View File

@@ -345,11 +345,12 @@ func (s *Server) Home(w http.ResponseWriter, r *http.Request) {
return return
} }
w.Header().Set("Content-Type", "text/html") w.Header().Set("Content-Type", "text/html")
if err := tmpl.Execute(w, map[string]any{ if err := tmpl.Execute(w, map[string]any{
"routePrefixes": routePrefixes, "routePrefixes": routePrefixes,
"domain": r.Host, "domain": r.Host,
"baseDomain": strings.Join(strings.Split(r.Host, ".")[1:], "."), "baseDomain": strings.Join(strings.Split(r.Host, ".")[1:], "."),
"scheme": r.URL.Scheme, "scheme": getScheme().String(),
}); err != nil { }); err != nil {
http.Error(w, err.Error(), http.StatusInternalServerError) http.Error(w, err.Error(), http.StatusInternalServerError)
return return