Commit fc25583836

fc25583836ac3f62300328807b53257c13be01a0

parent: a16d9f5622

Verified · cmc

cmc <hello@cleberg.net> · 2026-08-12 05:12 UTC

fix build: derive parent section from page.ancestors

page templates never receive a `section` variable, and tera raises on
the undefined name before `default()` can apply, so every page failed
to render. use get_section on the last ancestor instead. privacy pages
now link back to /privacy/ rather than the homepage.

Layout: unified · split

templates/page.html +2 −1
@@ -4,7 +4,8 @@
44{% block description %}{{ page.description | default(value=config.description) }}{% endblock description %}
55
66{% block content %}
7<p class="back"><a href="{{ section.permalink | default(value=get_url(path="/")) | safe }}">&larr; back</a></p>
7{% set parent = get_section(path=page.ancestors | last, metadata_only=true) %}
8<p class="back"><a href="{{ parent.permalink | safe }}">&larr; back</a></p>
89<article class="prose">
910 <h1 class="page-label">{{ page.title }}</h1>
1011 {% if page.description %}<p class="lede">{{ page.description }}</p>{% endif %}