This commit is contained in:
jdl committed 2025-01-04 13:36:55 +01:00
1 parent 2549e1ae08
commit 36172bf310
4 files changed
+13 -12

No files matched your search

+9 -9
View File
@@ -19,14 +19,14 @@ var templateFS embed.FS
type Config struct {
RootDir string
ListenAddr string
Secure bool
Insecure bool
}
type App struct {
api *api.API
mux *http.ServeMux
tmpl map[string]*template.Template
secure bool
api *api.API
mux *http.ServeMux
tmpl map[string]*template.Template
insecure bool
}
func NewApp(conf Config) (*App, error) {
@@ -36,10 +36,10 @@ func NewApp(conf Config) (*App, error) {
}
app := &App{
api: api,
mux: http.NewServeMux(),
tmpl: webutil.ParseTemplateSet(templateFuncs, templateFS),
secure: conf.Secure,
api: api,
mux: http.NewServeMux(),
tmpl: webutil.ParseTemplateSet(templateFuncs, templateFS),
insecure: conf.Insecure,
}
app.registerRoutes()