From 2940f00142ee45cb52946eada4389108590f142a Mon Sep 17 00:00:00 2001 From: bronkuu Date: Mon, 15 Jun 2026 15:05:52 +0200 Subject: [PATCH] fixed silent panics --- server/templates/cake.templ | 2 +- server/templates/cakes.templ | 2 +- server/templates/confirmation.templ | 2 +- server/templates/order.templ | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/server/templates/cake.templ b/server/templates/cake.templ index f13d6cc..3a3cc8e 100644 --- a/server/templates/cake.templ +++ b/server/templates/cake.templ @@ -7,7 +7,7 @@ import ( ) templ CakePage(cake models.Cake) { - @Layout(cakeTitle(cake), nil, CakeForm(cake)) + @Layout(cakeTitle(cake), templ.NopComponent, CakeForm(cake)) } templ CakeForm(cake models.Cake) { diff --git a/server/templates/cakes.templ b/server/templates/cakes.templ index a1091dd..81f2ff4 100644 --- a/server/templates/cakes.templ +++ b/server/templates/cakes.templ @@ -7,7 +7,7 @@ import ( ) templ CakesPage(cakes []models.Cake) { - @Layout("Katalog", nil, CakesMain(cakes)) + @Layout("Katalog", templ.NopComponent, CakesMain(cakes)) } templ CakesMain(cakes []models.Cake) { diff --git a/server/templates/confirmation.templ b/server/templates/confirmation.templ index d8851b0..dfa1e57 100644 --- a/server/templates/confirmation.templ +++ b/server/templates/confirmation.templ @@ -3,7 +3,7 @@ package templates import "strconv" templ Confirmation(title string, id int) { - @Layout(title, nil, ConfirmationBody(id)) + @Layout(title, templ.NopComponent, ConfirmationBody(id)) } templ ConfirmationBody(id int) { diff --git a/server/templates/order.templ b/server/templates/order.templ index 7671c81..a6ea0a0 100644 --- a/server/templates/order.templ +++ b/server/templates/order.templ @@ -7,7 +7,7 @@ import ( ) templ OrderPage(order models.Order, catalogue []models.Cake) { - @Layout(orderTitle(order), nil, OrderForm(order, catalogue)) + @Layout(orderTitle(order), templ.NopComponent, OrderForm(order, catalogue)) } templ OrderForm(order models.Order, catalogue []models.Cake) {