aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/templates.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/templates.go')
-rw-r--r--src/templates.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/templates.go b/src/templates.go
index 20fcf79..353c755 100644
--- a/src/templates.go
+++ b/src/templates.go
@@ -46,6 +46,12 @@ func BuildTemplates(dir fs.FS, debugp bool) {
buildAndSetTemplate(dir, name)
if debugp {
go watch.FileFS(dir, name, func() {
+ defer func() {
+ if p := recover(); p != nil {
+ log.Print(p)
+ }
+ }()
+
buildAndSetTemplate(dir, name)
log.Printf("Template ā€˜%s’ updated\n", name)
})