Stop rendering canonical links when origin is missing from config

This commit is contained in:
2026-08-14 17:00:07 +02:00
parent 58eebac637
commit 1a5f3bfc67
+1 -1
View File
@@ -6,7 +6,7 @@
<title>{% block title %}{{ site.name }}{% endblock %}</title> <title>{% block title %}{{ site.name }}{% endblock %}</title>
<link rel="stylesheet" href="{{ site.base_dir }}/assets/style.css"> <link rel="stylesheet" href="{{ site.base_dir }}/assets/style.css">
<link rel="stylesheet" href="{{ site.base_dir }}/assets/pygments.css"> <link rel="stylesheet" href="{{ site.base_dir }}/assets/pygments.css">
<link rel="canonical" href="{{ site.origin }}{{ page.url }}"> {% if site.origin %}<link rel="canonical" href="{{ site.origin }}{{ page.url }}">{% endif %}
{% block head %}{% endblock %} {% block head %}{% endblock %}
</head> </head>
<body> <body>