feat: Asegurar que las banderas de navegación existan para evitar ReferenceError en las plantillas
This commit is contained in:
@@ -536,6 +536,13 @@ const renderTemplate = async (
|
|||||||
month: "long",
|
month: "long",
|
||||||
year: "numeric",
|
year: "numeric",
|
||||||
}),
|
}),
|
||||||
|
// ensure nav flags exist to avoid ReferenceError inside templates
|
||||||
|
hideNavbar:
|
||||||
|
typeof locals.hideNavbar !== "undefined" ? locals.hideNavbar : false,
|
||||||
|
useDashboardNav:
|
||||||
|
typeof locals.useDashboardNav !== "undefined"
|
||||||
|
? locals.useDashboardNav
|
||||||
|
: false,
|
||||||
...locals,
|
...locals,
|
||||||
title: locals.title ?? defaultTitle,
|
title: locals.title ?? defaultTitle,
|
||||||
body: pageBody,
|
body: pageBody,
|
||||||
|
|||||||
Reference in New Issue
Block a user