Base64 encode note titles
This commit is contained in:
parent
eb0c264ad7
commit
6f8796c83f
6 changed files with 78 additions and 22 deletions
|
|
@ -11,6 +11,7 @@ import (
|
|||
type Ctx map[string]any
|
||||
|
||||
func RenderTemplate(w http.ResponseWriter, tmpl string, context any) error {
|
||||
var err error
|
||||
files := []string{
|
||||
filepath.Join("templates", "base.tmpl.html"),
|
||||
filepath.Join("templates", tmpl),
|
||||
|
|
@ -25,6 +26,6 @@ func RenderTemplate(w http.ResponseWriter, tmpl string, context any) error {
|
|||
}
|
||||
|
||||
t, err := template.ParseFS(conf.Templates, files...)
|
||||
t.ExecuteTemplate(w, "base", context)
|
||||
err = t.ExecuteTemplate(w, "base", context)
|
||||
return err
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue