handleHome handles the home page.
(w http.ResponseWriter, r *http.Request)
| 62 | |
| 63 | // handleHome handles the home page. |
| 64 | func handleHome(w http.ResponseWriter, r *http.Request) { |
| 65 | if r.URL.Path != "/" { |
| 66 | handleNotFound(w) |
| 67 | return |
| 68 | } |
| 69 | t := template.Must(template.ParseFS(filesTempl, "template/template.html", "template/navbar.html", "template/home.html")) |
| 70 | t.ExecuteTemplate(w, "layout", map[string]string{"Page": "home"}) |
| 71 | } |
| 72 | |
| 73 | // handleMessages handles the messages page. |
| 74 | func handleMessages(cr *redis.Client) func(w http.ResponseWriter, r *http.Request) { |
nothing calls this directly
no test coverage detected